Click here to Skip to main content
15,899,679 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to start another application and run it within another application Pin
Muhammad Azam3-Oct-04 23:22
Muhammad Azam3-Oct-04 23:22 
GeneralRe: How to start another application and run it within another application Pin
Kiran Satish4-Oct-04 7:02
Kiran Satish4-Oct-04 7:02 
GeneralRe: How to start another application and run it within another application Pin
Kiran Satish4-Oct-04 7:14
Kiran Satish4-Oct-04 7:14 
GeneralRe: How to start another application and run it within another application Pin
Muhammad Azam4-Oct-04 21:44
Muhammad Azam4-Oct-04 21:44 
GeneralRe: How to start another application and run it within another application Pin
Kiran Satish5-Oct-04 14:11
Kiran Satish5-Oct-04 14:11 
GeneralRe: How to start another application and run it within another application Pin
Muhammad Azam5-Oct-04 20:24
Muhammad Azam5-Oct-04 20:24 
GeneralExitProcess Pin
elephantstar28-Sep-04 12:58
elephantstar28-Sep-04 12:58 
GeneralRe: ExitProcess Pin
Antti Keskinen28-Sep-04 18:01
Antti Keskinen28-Sep-04 18:01 
After the process is created, you can use pProcessInfo and OpenProcess to obtain a handle to the running process (pProcessInfo.hProcess). Giving this handle to TerminateProcess will instantly kill the running application. Note that this is the same thing as using CTRL+ALT+DEL on a Windows XP machine: the target process is not notified that it is closing, but is terminated instantly. If you're operating on a Word document to which the user can read, write and save, then using TerminateProcess is a sure way to lose all unsaved work. It will not ask questions or confirmations: it will just kill the process, straight through.

After the process is terminated, GetExitCodeProcess will return the exit code with which the primary thread of the application exited.

Is this what you asked for ?

-Antti Keskinen

----------------------------------------------
The definition of impossible is strictly dependant
on what we think is possible.
GeneralRe: ExitProcess Pin
elephantstar29-Sep-04 7:23
elephantstar29-Sep-04 7:23 
GeneralInvalid CTempWnd problem Pin
PJ Arends28-Sep-04 12:57
professionalPJ Arends28-Sep-04 12:57 
GeneralRe: Invalid CTempWnd problem Pin
Antti Keskinen28-Sep-04 18:08
Antti Keskinen28-Sep-04 18:08 
GeneralRe: Invalid CTempWnd problem Pin
PJ Arends29-Sep-04 6:21
professionalPJ Arends29-Sep-04 6:21 
GeneralRe: Invalid CTempWnd problem Pin
Antti Keskinen29-Sep-04 6:40
Antti Keskinen29-Sep-04 6:40 
GeneralDatabase replication - network and island Pin
Ted Christiansen28-Sep-04 11:56
Ted Christiansen28-Sep-04 11:56 
GeneralRe: Database replication - network and island Pin
ssanoj29-Sep-04 9:59
ssanoj29-Sep-04 9:59 
GeneralSetForegroundWindow fails Pin
Neville Franks28-Sep-04 11:47
Neville Franks28-Sep-04 11:47 
GeneralRe: SetForegroundWindow fails Pin
vcplusplus28-Sep-04 12:14
vcplusplus28-Sep-04 12:14 
GeneralRe: SetForegroundWindow fails Pin
vcplusplus28-Sep-04 12:30
vcplusplus28-Sep-04 12:30 
GeneralRe: SetForegroundWindow fails Pin
Neville Franks28-Sep-04 13:07
Neville Franks28-Sep-04 13:07 
GeneralRe: SetForegroundWindow fails Pin
Neville Franks28-Sep-04 13:42
Neville Franks28-Sep-04 13:42 
GeneralRe: SetForegroundWindow fails Pin
Scott H. Settlemier28-Sep-04 14:46
Scott H. Settlemier28-Sep-04 14:46 
GeneralRe: SetForegroundWindow fails Pin
Neville Franks28-Sep-04 15:15
Neville Franks28-Sep-04 15:15 
GeneralRe: SetForegroundWindow fails Pin
Phil J Pearson29-Sep-04 3:49
Phil J Pearson29-Sep-04 3:49 
GeneralRe: SetForegroundWindow fails Pin
Neville Franks29-Sep-04 10:34
Neville Franks29-Sep-04 10:34 
GeneralRe: SetForegroundWindow fails Pin
Phil J Pearson29-Sep-04 10:53
Phil J Pearson29-Sep-04 10:53 

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.