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:
00691501
Views:
21
>Ok, that worked for Notepad. In my test for my app, I have:
>
>
>tcwindow = "Spot Media Tracking System - Kevin Marois"
>
>lnhwnd = FindWindow(0,tcwindow)
>
>
>
>and FindWindow is returning Zero
>
>I added GetLastError, which returned 127. From my VB API Guide, I read
>that to be:
>
>* The specified procedure could not be found.
>#DEFINE ERROR_PROC_NOT_FOUND 127
>
>Any ideas on this?

The one thing that is kind of a pain is that FindWindow has to have EXACTLY the same string as what the window has. If it doesn't, it won't find the window. Make sure the case is correct and that you don't have any additional spaces at the end of the window name, or embedded control characters (in VFP).
-Paul

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

Click here to load this message in the networking platform