Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
I need to get the list of applications working
Message
From
09/10/2000 11:25:49
 
 
To
09/10/2000 07:39:10
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00426736
Message ID:
00426828
Views:
33
>What is wrong here
>
>Thanks
>
> DECLARE INTEGER GetWindow IN win32api ;
> INTEGER ncurr_window_handle, ;
> INTEGER ndirection
>
> DECLARE INTEGER GetWindowText IN win32api ;
> INTEGER n_win_handle, ;
> STRING @ cwindow_title, ;
> INTEGER ntitle_length
>
> DECLARE INTEGER EnumWindows IN win32api ;
> INTEGER lpEnumFunc, ;
> INTEGER lparam
>

You can't use EnumWindows - it requires a callback address, and VFP doesn't have a way of doing this. Christof Lange posted code for creating an FLL to handle limited callbacks about 3 years ago; you might want to look for that. It'll require you to do some work in VC++ to create the callback handler if Christof didn't provide one for EnumWindows.

> ret = EnumWindows(EnumWindowsProc(), 0)
>
>
>FUNCTION EnumWindowsProc(hwnd, lParam)
> ? hwnd
> buffer = SPACE(255)
> cWinCap = GetWindowText(hwnd, buffer, LEN(buffer))
> RETURN 1
>ENDFUNC
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Reply
Map
View

Click here to load this message in the networking platform