Windows with Delphi Windows API (94) Windows Filesystem (41) Windows Forms (69) Windows Graphics (38)
Exchange Links About this site Links to us 
|
Disabling and Enabling of the start menu (start button)
This article has not been rated yet. After reading, feel free to leave comments and rate it.
The Windows start menu is opened by clicking on the start button which is just a windowed control as others on your desktop. Thus you can show or hide, enable or disable it.
The key is to obtain the window handle of your start button. The code in the other example (see above 'Show/ Hide the Start button') is a bit long since it checks for errors.
If you want to write real compact code, take a look at this one:  | |  | | procedure EnableStartbutton(bEnabled: Boolean);
begin
EnableWindow(FindWindowEx(FindWindow('Shell_TrayWnd', nil) ,0 ,'Button' ,nil), bEnabled)
end; | |  | |  | You don't like the formatting? Check out SourceCoder then!
Comments:
|