Hey all!!
I am using the ShellExecute command......
Why doesn't using "notepad.exe fil.txt" work??
//-------- Sample code
#include <shellapi.h>
ExecuteFile("notepad.exe fil.txt"," ", "C:\\[Full_Path]", SW_SHOWMINIMIZED);
int __fastcall ExecuteFile(const AnsiString FileName,
const AnsiString Params,
const AnsiString DefaultDir,
int ShowCmd)
{
char zFileName[79], zParams[79], zDir[79];
return (int) ShellExecute(Application->MainForm->Handle,
NULL,
strcpy(zFileName,
FileName.c_str()),
strcpy(zParams,
Params.c_str()),
strcpy(zDir,
DefaultDir.c_str()),
ShowCmd);
}
Martin G Broman
mgb_svea@hotmail.com
DWS - Alpha Whitin Dead Wolf Society
I am using the ShellExecute command......
Why doesn't using "notepad.exe fil.txt" work??
//-------- Sample code
#include <shellapi.h>
ExecuteFile("notepad.exe fil.txt"," ", "C:\\[Full_Path]", SW_SHOWMINIMIZED);
int __fastcall ExecuteFile(const AnsiString FileName,
const AnsiString Params,
const AnsiString DefaultDir,
int ShowCmd)
{
char zFileName[79], zParams[79], zDir[79];
return (int) ShellExecute(Application->MainForm->Handle,
NULL,
strcpy(zFileName,
FileName.c_str()),
strcpy(zParams,
Params.c_str()),
strcpy(zDir,
DefaultDir.c_str()),
ShowCmd);
}
Martin G Broman
mgb_svea@hotmail.com
DWS - Alpha Whitin Dead Wolf Society