Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Stopping a process
Message
From
03/08/2010 12:52:43
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
Miscellaneous
Thread ID:
01029879
Message ID:
01475007
Views:
48
>
>Yes, I did it - but it seems like it behaves the same as close in the right corner of the screen, as my question - do you want to close application, is now asked.
>
>In other words, what exactly does this code simulate?

It sends a WM_CLOSE as if you wanted to close the app with the closebox

Why all the hassle ? Bypass your question for the tests - or better - click via taskbar - no code needed

>
>#define PROCESS_ALL_ACCESS (0x000F0000 + 0x00100000 + 0x0FFF)
>
>#define WM_CLOSE                  0x0010
>
>DECLARE INTEGER FindWindow ;
>IN WIN32API STRING cNull, STRING cWinName
>
>	declare integer PostMessage in user32.dll long, long, long, long
>	
>
>LOCAL lnHwnd
>lnHwnd = FindWindow(0,'SysManager 9.0.00')	
>	
>=PostMessage(lnHWnd, WM_CLOSE, 0, 0)
>	
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform