Topic: Firing up other applications from a c/c++ app
How do I start another program/application using c/c++, I want to start outlook express once my program has completed it task.
Paul M
You are not logged in. Please login or register.
PunBB Forums → Programming → Firing up other applications from a c/c++ app
How do I start another program/application using c/c++, I want to start outlook express once my program has completed it task.
Paul M
Well.. I haven't tried it, but can't system() run dos commands?
This runs Outlook Express
#include <shlobj.h>
#include <shlwapi.h>
void Test()
{
SHELLEXECUTEINFO ShExecInfo;
ShExecInfo.cbSize = sizeof(SHELLEXECUTEINFO);
ShExecInfo.fMask = NULL;
ShExecInfo.hwnd = NULL;
ShExecInfo.lpVerb = NULL;
ShExecInfo.lpFile = "msimn.exe";
ShExecInfo.lpParameters = NULL;
ShExecInfo.lpDirectory = NULL;
ShExecInfo.nShow = SW_MAXIMIZE;
ShExecInfo.hInstApp = NULL;
ShellExecuteEx(&ShExecInfo);
}
BUT
I suspect you dont really want to do that, What happens if the user does not
have Outlook Express, you should really run the application that is
registered with emails.
replace "msimn.exe"
with
"mailto:someone@sonthing.com"
PunBB Forums → Programming → Firing up other applications from a c/c++ app
Powered by PunBB, supported by Informer Technologies, Inc.