procedure WndHide(ishide:boolean); //untuk menyembunyikan program klien dari taskbar
begin
if ishide then begin
// jauhkan kooordinat form sejauh mungkin
form1.Left := 99999;
form1.Top := 99999;
// form1 hilang
form1.Visible := false;
Application.Minimize;
// hilangkan dari taskbar, dengan menset tipe window mjd window tool
ShowWindow(Application.Handle, SW_HIDE);
SetWindowLong(Application.Handle, GWL_EXSTYLE,
GetWindowLong(Application.Handle, GWL_EXSTYLE)
or WS_EX_TOOLWINDOW );
end
else begin
//set koordinat form1
form1.Left := 220;
form1.Top := 205;
//tampilkan form1
form1.Show;
//tempatkan aplikasi di paling depan desktop (topmost)
setwindowpos(form1.Handle,HWND_TOPMOST,form1.Left,form1.Top,form1.Width,form1.Height,SWP_SHOWWINDOW);
end;
end;
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.