Invoking A DOS Program Through A "C" Program

From: ~neil~ (neilwrites2_at_hotmail.com)
Date: 09/23/04


Date: 23 Sep 2004 14:25:39 -0700

hello

I'm fairly new to the language, and my problem is I'm trying to write
a program to run a command from the DOS prompt "C:>". I don't know all
the functions in "C", however there are a few under the header file
"process.h" that could be used, but I'm not really sure what they
mean. I only know them by their name <prototype declaration>. I don't
understand the arguments that are passed down to these functions, is
why I'm seeking help to write this small program.

Functions like: "spawnl", "spawnle", "spawnlvpe" or "execl" to make a
parent program invoke or run a child process program like "qbasic.exe"
for example. I set up the PATH statement <Enviroment Command> in the
autoexec.bat file in C directory to bring up the application from the
DOS prompt.

With my limited knowledge of pointers, I'm little unsure how this is
written in "C". Could anyone help me with the code for the program as
described here.

<Inside the Win32 console window>

Starting...
Running DOS Command. . .

Press any key to continue. . .

This is more advanced C programming....... I'm still learning:)

Thanks
Neil



Relevant Pages

  • "ntldr is compressed" error
    ... I was copying files to an external hard drive when Windows Explorer ... I got to the blue HP screen (F1 for setup, F10 for system recovery), ... DOS prompt and typing the command: ...
    (microsoft.public.windows.mediacenter)
  • Re: Weatherbug
    ... How do I get into a DOS prompt? ... Run and enter cmd.exe as the command. ... A black window should open. ... In any OS of note, there is an execution path, ...
    (microsoft.public.windowsxp.general)
  • Re: Error when using mcc command
    ... OK, now try running the mbuild command explicitly, both from within MATLAB ... and at a DOS prompt. ...
    (comp.soft-sys.matlab)
  • Re: Waiting for VB Process to Complete
    ... >>processes which can be run from a DOS prompt. ... > only execute processes which can be run from a DOS prompt. ... Start|Run box will also run from the command prompt. ... I am using Windows 2000, ...
    (microsoft.public.vb.general.discussion)
  • Re: How to Define a global const class variable in MFC?
    ... generated by MFC, The actual name of class is CCommandCollection ... // CCommandCollection command target ... First CDevCommand that its header file is included in header file of ...
    (microsoft.public.vc.mfc)