Start is ok for starting documents....but the downside is that it loads a console window for a few seconds.......To do this without the window you could make your own file opener like so....
Originally posted by dazed66
this is what you want
you must add the start to start non-executable programs...
Compile this as StartW.exe and add it on the CD with the text.txt. Now change the
int WINAPI WinMain(HINSTANCE hThisInstance,
HINSTANCE hPrevInstance, LPSTR lpszArgument,
CHAR szDir[MAX_PATH +1]; //Name of directory
GetCurrentDirectory(MAX_PATH +1,szDir);//Where is this prog run?
MessageBox(HWND_DESKTOP,"Could not open file",//Error
"Error",MB_ICONEXCLAMATION | MB_OK);
and it should open without the annoying console window....
Another way I guess is to use
This will open the notepad app with the document you specify...the big downside is that you dont know that notepad is where you specified (it is differet on NT, Win2k...) and also you dont know that the user likes to use notepad...they may like another text editor such as textpad (the program I did above will ask the system to open the file...therefore it will know the prefered text editor)