Quantcast
Channel: CodeGuru Forums - Visual C++ Programming
Viewing all articles
Browse latest Browse all 3029

How to kill Excel process?

$
0
0
Hi,
I'm doing an action in first debug like this:
1, Create excel instance.
2, During debugging, turn it off suddenly.
In some case, this processes still run in background,
so when i use getobject code get the instance but now they are no longer valid.

I used the following code in second debug but it doesn't work?

//check [getobject] if catch error then terminate process and create new one:
::PostMessage(hWnd, WM_CLOSE, 0, 0);

How do I kill this process?

Name:  bug1.png
Views: 19
Size:  13.8 KB

Thanks you!
Attached Images
 

Viewing all articles
Browse latest Browse all 3029

Latest Images

Trending Articles



Latest Images