Click here to Skip to main content
15,909,605 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Disable "promt me to save passwords" Pin
jmkhael13-Jul-04 7:18
jmkhael13-Jul-04 7:18 
GeneralRe: Disable "promt me to save passwords" Pin
Volum13-Jul-04 7:30
sussVolum13-Jul-04 7:30 
GeneralRe: Disable "promt me to save passwords" Pin
David Crow13-Jul-04 7:56
David Crow13-Jul-04 7:56 
GeneralRe: Disable "promt me to save passwords" Pin
Volum14-Jul-04 7:16
sussVolum14-Jul-04 7:16 
Generalmenu's Pin
locoone13-Jul-04 6:49
locoone13-Jul-04 6:49 
GeneralRe: menu's Pin
Ravi Bhavnani13-Jul-04 7:11
professionalRavi Bhavnani13-Jul-04 7:11 
GeneralRe: menu's Pin
locoone13-Jul-04 7:16
locoone13-Jul-04 7:16 
GeneralSystem/CreateProcess'd process terminating Pin
mike-o13-Jul-04 6:30
mike-o13-Jul-04 6:30 
Hi Everyone,

I'm hooking a dos-based calculation engine("engine.exe") up to my GUI, and am having some problems. When I double click the engine.exe file, or run it from cmd it runs to completion and produces the correct output.

However when i attempt to run it from my program using either createprocess, or system(), it does not run and gives this output.
Abnormal program termination: Memory protection fault
CS:EIP = 01FFh:0000799Ch

I have swapped out the engine.exe path for several other programs, and they all work just fine from createprocess.

here is my createprocess line
fSuccess = CreateProcess((LPTSTR)ImageName,//Path + engine.exe
		(LPTSTR)CmdLine,// ""
		(LPSECURITY_ATTRIBUTES)NULL, 
		(LPSECURITY_ATTRIBUTES)NULL,
		(BOOL)TRUE,(DWORD)0,NULL,
		(LPTSTR)DirLine, // working dir
		(LPSTARTUPINFO)&SI,(LPPROCESS_INFORMATION)& pi); 


and startupinfo
SI.cb =sizeof(STARTUPINFO);
SI.lpReserved = NULL;
SI.lpDesktop=NULL;
SI.lpTitle="EngineProcess";
SI.cbReserved2=0;
SI.lpReserved2=NULL;
SI.dwFlags = STARTF_USESHOWWINDOW;// enables SI.wShowWindow to work
SI.wShowWindow = SW_FORCEMINIMIZE;//hide the dow window

I'm just wondering if anyone has seen this before(unable to run dos-based programs from a VC++ program).

thanks,

Mike

"I bet Einstein turned himself all sorts of colors before he invented the light bulb." -- Homer J.
GeneralRe: System/CreateProcess'd process terminating Pin
jmkhael13-Jul-04 6:50
jmkhael13-Jul-04 6:50 
GeneralRe: System/CreateProcess'd process terminating Pin
mike-o13-Jul-04 7:04
mike-o13-Jul-04 7:04 
GeneralRe: System/CreateProcess'd process terminating Pin
bikram singh13-Jul-04 7:04
bikram singh13-Jul-04 7:04 
GeneralRe: System/CreateProcess'd process terminating Pin
mike-o14-Jul-04 10:21
mike-o14-Jul-04 10:21 
GeneralRe: System/CreateProcess'd process terminating Pin
bikram singh14-Jul-04 10:38
bikram singh14-Jul-04 10:38 
GeneralRe: System/CreateProcess'd process terminating Pin
mike-o14-Jul-04 10:43
mike-o14-Jul-04 10:43 
GeneralSetting The Current Directory Pin
sweep12313-Jul-04 5:44
sweep12313-Jul-04 5:44 
GeneralRe: Setting The Current Directory Pin
palbano13-Jul-04 5:52
palbano13-Jul-04 5:52 
GeneralRe: Setting The Current Directory Pin
sweep12313-Jul-04 6:04
sweep12313-Jul-04 6:04 
GeneralRe: Setting The Current Directory Pin
palbano13-Jul-04 6:48
palbano13-Jul-04 6:48 
GeneralRe: Setting The Current Directory Pin
sweep12313-Jul-04 21:51
sweep12313-Jul-04 21:51 
GeneralRe: Setting The Current Directory Pin
bikram singh13-Jul-04 6:13
bikram singh13-Jul-04 6:13 
GeneralRe: Setting The Current Directory Pin
sweep12313-Jul-04 6:26
sweep12313-Jul-04 6:26 
GeneralRe: Setting The Current Directory Pin
bikram singh13-Jul-04 6:54
bikram singh13-Jul-04 6:54 
Generaltitlebar text Pin
Ahmed Kamal Aly13-Jul-04 5:35
Ahmed Kamal Aly13-Jul-04 5:35 
GeneralIntercept WM_NCPAINT Pin
bikram singh13-Jul-04 6:13
bikram singh13-Jul-04 6:13 
GeneralRe: titlebar text Pin
Jens Doose13-Jul-04 6:18
Jens Doose13-Jul-04 6:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.