Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need To Close An Application
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00691241
Message ID:
00691252
Views:
15
>I need to close an application from within VFP. I know
>that title of the application. What's the API call
>for this? Thanks
#DEFINE WM_CLOSE 			0x10

DECLARE INTEGER SendMessage IN WIN32API ;
        INTEGER hWnd, ;
        INTEGER Msg, ;
        INTEGER wParameter, ;
        INTEGER lParameter

DECLARE INTEGER FindWindow IN Win32API STRING, STRING

hWnd = FindWindow(0, "My Application Window Name")
   
=SendMessage(hWnd, WM_CLOSE, 0, 0)
-Paul

RCS Solutions, Inc.
Blog
Twitter
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform