At 4/28/2009 06:12 AM, you wrote:
>Hi All,
>
>I am writing a program in C++ which needs an input file generated from
>another executable.
><SNIP>
>I am calling the above command using Createprocess function from my
>program's main() giving the "C:\Program Files\Wireshark\tshark.exe" as
>application name and rest of the field as command line arguments, but Its
>not working.
>Can somebody guide me on this ....I have already tried other options like
>system() and WinExec() but I'm getting errors as these function are not able
>to parse the input arguments.

You don't say what is not working, and I am not familiar with 
CreateProcess but I'm guessing you need to wait and check to make 
sure the CreateProcess completes before continuing in your code path. 
You may be trying to read to output of the command before the command 
completes.

~Rick 

Reply via email to