unit Unit5;<br><br>interface<br><br>uses<br> Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,<br> Dialogs, StdCtrls;<br><br>type<br> TForm5 = class(TForm)<br> Button1: TButton;<br> Button2: TButton;<br> procedure Button1Click(Sender: TObject);<br> procedure Button2Click(Sender: TObject);<br> private<br> { Private declarations }<br> public<br> { Public declarations }<br> end;<br>var<br> Form5: TForm5;<br> hDeskTop,wndhandle:Thandle;<br><br>implementation<br><br>{$R *.dfm}<br><br>procedure TForm5.Button1Click(Sender: TObject);<br>begin<br> hDesktop :=FindWindow('Progman', nil);<br> EnableWindow(hDeskTop,false);<br> wndHandle :=FindWindow(pchar('Shell_TrayWnd'), nil);<br> EnableWindow(wndHandle,false);<br>end;<br><br>procedure TForm5.Button2Click(Sender: TObject);<br>begin<br> EnableWindow(hDeskTop,true);<br> EnableWindow(wndHandle,true);<br>end;<br><br>end.