Hi,
I use JP Software's 4NT as my command shell in place of the built-in CMD.EXE whenever I can. Is there any way to make 4NT the command processor for the Tools|DOS Command Line... and Tools|DOS Shell menu options? If not, is there any chance of adding this as an option?
Cheers,
Tony
DOS Command Line replacement
Zeus uses the COMSPEC environment variable to determine the command processor, so you should be able to set this variable to point to any alternative command interpreter.
For example here is the code Zeus uses this get the command line interpreter from this variable:
Then when Zeus runs any pszCommandLine command line it builds up a command line as follows:
Also when Zeus opens a command line shell it does the following:
Cheers Jussi
For example here is the code Zeus uses this get the command line interpreter from this variable:
Code: Select all
//-- look for the environment variable
char *pszComspec = getenv("COMSPEC");
if (pszComspec)
{
//-- use the commanf line processor found
szComspec = pszComspec;
}
else
{
//-- use the NT or windows command line processor
szComspec = (IsNT()) ? "cmd.exe" : "command.com";
}
Code: Select all
//-- get the command processor (ie the code above)
GetComspec(szCommandLine);
//-- add the "/c = kill session when complete" option
szCommandLine += " /c ";
//-- add in the remaining command line to be run
szCommandLine += pszCommandLine;
//-- run the command line
return this->run(szCommandLine);
Code: Select all
bool Spawn::shell()
{
String szCommandLine;
//-- get the command processor (ie the code above)
GetComspec(szCommandLine);
//-- add the "/k = keep session open" option to the command line
szCommandLine += " /k";
//-- open the shell
return this->run(szCommandLine);
}