Many Thanks - I can trap the command line and not show the dialog box using follwoing code,
Code:
CString cmdLine = this->m_lpCmdLine;
if (cmdLine.Compare("-t") == -1)
{
int nResponse = dlg.DoModal();
if (nResponse == IDOK)
{
// TODO: Place code here to handle when the dialog is
// dismissed with OK
}
else if (nResponse == IDCANCEL)
{
// TODO: Place code here to handle when the dialog is
// dismissed with Cancel
}
}
else
{
dlg.commandLineSwitch(cmdLine);
}
If from command line, I call the commandLineSwitch function.
I want to be able to send output to the console, but when using cout, nothing is displayed.
Do I hae to change the output stream, and if so how do I do it?
Many Thanks
Magic