Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determining if a window is a VFP editor window
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
01451683
Message ID:
01451733
Views:
67
>Is there a foolproof way of determining if a window (given either it's hWnd or WHandle) is a VFP code editor window? I've been using _EdGetEnv (and checking for a return value of 0) but it seems to fail under various circumstances (that is, _EdGetEnv seems to throw an exception). I thought about using the Win32 GetClassName() call but I don't see anything that differentiates something like the Property window from the editor Window (it seems some windows DO return a slightly different result, though).

I guess that _EdGetEnv throws exeption on noe-editor windows, right?
Why don't you wrap calls to _EdGetEnv in TRY...ENDTRY?
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform