Link to home
Start Free TrialLog in
Avatar of tomatocans
tomatocans

asked on

Running a C Program from MS-DOS

I have a C program that has a PC executable and Unix executable. In Windows 95 I can access the MS-DOS window by going to run and typing command. How do I get the program to run. The executable in in Unix in the path /devel/airspace99/.  MS DOS defaults to
C:\WINDOWS\DESKTOP. How can I get this thing to run on a pc through MS DOS?
Avatar of imladris
imladris
Flag of Canada image

Not quite clear on where you're stuck.
Perhaps a description will help.

In MS DOS the system takes commandline input. The first word on the line is taken to be an internal or external command. If it is an internal command (such as "copy") the command processor executes it. If it is not an internal command, it is assumed to be an external command, it a program of that name is searched for. MS DOS will look in the current directory, the in each directory on the path in turn (type "path" to see what your path is) looking for "progname.com" or "progname.exe".

I'm not sure what relevance the location of your program in a Unix system (/devel/airspace99) has to this problem.

It can also be executed directly by specifying the whole path. Open an MS DOS window (or boot your DOS machine) and type c:\dir1\dir2\dir3\progname, where c, is the drive it is on, dir1-3 are the directories on the path.
Avatar of tomatocans
tomatocans

ASKER

does only the executable have to be in this directory
u can run any c executable program (.exe) simply by giving the path
u can make that in a command
I put path=C:\RM\ResourceMonitor_v4.0.exe

nothing
ASKER CERTIFIED SOLUTION
Avatar of imladris
imladris
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks