Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Disabling Start Menu VB to VFP
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
Oracle
Miscellaneous
Thread ID:
01074789
Message ID:
01074861
Views:
17
Martin I get errors trying your code. Does it work for you?

I have better success using this
DECLARE LONG FindWindow IN "user32" STRING lpClassName, STRING lpWindowName
DECLARE LONG SendMessage IN "user32" LONG hWnd, LONG wMsg, LONG wParam, LONG lParam
DECLARE LONG FindWindowEx IN "user32" LONG hWnd1, LONG hWnd2, STRING lpsz1, STRING lpsz2
#DEFINE WM_CLOSE 0x10
SendMessage(FindWindowEx(FindWindow("Shell_TrayWnd", ""), 0x0, "Button", .NULL.), WM_CLOSE, 0, 0)
>Hi Aashish,
>
>
>Declare INTEGER FindWindowEx IN user32.dll ;
>         Long, Long, string, String
>
>Declare INTEGER EnableWindow Lib user32.dll Long, Long)
>
>=EnableStartMenuButton(0)
>=INKEY(10)
>=EnableStartMenuButton(1)
>
>PROCEDURE EnableStartMenuButton(liEnable)
>* Don't forget to re-enable it !
>LOCAL lHwnd
>lHwnd = FindWindowEx(0&, 0&, "Shell_TrayWnd", .NULL.)
>lHwnd = FindWindowEx(lHwnd, 0&, "Button", .NULL.)
>=EnableWindow(lHwnd, liEnable)
>
>
>MartinJ
>
>>Hi Friends
>>
>>One from disabling windows start button code, needs a conversion to VFP
>>
>>
>>This small code sample shows how to disable
> the Start Menu button through code, simply paste
> it into a BAS module and use :
>>
>>
>>
>>'
>>' Paste this into a Code Mode (BAS)
>>'
>>option Explicit
>>
>>
>>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform