Original Post
Hey folks, I'm in that "just learning windows API" phase(with c++), where its becoming plain that I know enough to get me in trouble but not enough to really accomplish anything I want to do:P At the moment, Im simply trying to tell windows to execute a program (that is specified by path) along with another file as an argument. Using system(), I can call the program with no arguments, ie
system("\"c:\\Documents and Settings\\etc\\whatever.exe\"");
to feed the command line the windows dir in quotes, and it launches. But if I want to pass the program another filename as an arg(as in open this file), system seems to break, ie
system("\"c:\\Documents and Settings\\etc\\whatever.exe\ c:\test.wtf\"");
Its almost as if the system drops the "'s around the string, and pukes up a " 'c:\Documents' is not a real command" Apart from all that, I know system() causes the process to wait until the executed program completes, and therefore is a horrible choice, and leaves me wondering what the simplest(oh I hope its simple) true Win32 method for just telling the OS to launch a program is. I've tried working it out via google or msdn, but generic terms like "win32 api shell execute program" return a very wide berth of results and I havent picked up a clue yet.