Solved

Question in C

Posted on 2000-03-08
4
189 Views
Last Modified: 2010-04-02
How can i run a executable file(other than c file ) such as a .class file
from a c program ??
0
Comment
Question by:yammanur
  • 3
4 Comments
 
LVL 1

Expert Comment

by:dmaguillo
ID: 2595545
All you need is execute from your command prompt (for a java .class):

   java mainfile.class (main application)
   appletviewer miapplet.class

You must specify this command lines in your c function for execute programs from command prompt.

Bye... :)
0
 
LVL 22

Expert Comment

by:nietod
ID: 2595610
Is a .class file executable?   I've never heard of it.

You can run any executable program (anything you can run from a command line) using the system() command.  Like

system("C:\PROGRAMMS\\WINWORD.EXE");

will run the WINWORD.EXE program.

In addition, there may be other ways to run programs on your operating system.  But since you didn't say what operating system you are using so we can't suggest any.
0
 
LVL 22

Accepted Solution

by:
nietod earned 95 total points
ID: 2600155
What is going on here?  Why did you reject my answer?
0
 
LVL 22

Expert Comment

by:nietod
ID: 2604212
You don't have to accept it if it doesn't help you, but you do need to explain why it didn't help you.   When you reject and answer with no comment, it is not clear what was wrong so no one knows what to help you.  Also it looks like you might be cheating the system--rejecting a correct answer so you don't have to pay for it.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now