procedure TForm1.CheckBox1Click(Sender: TObject); begin SetWindowLong(Handle, GWL_STYLE, GetWindowLong(Handle, GWL_STYLE) xor WS_CAPTION); if not CheckBox1.Checked then begin Hide; Show; end; end;
procedure TForm1.MyMsg(var Msg: TWMNCHitTest); begin Inherited; if Msg.Result = HTCLIENT then Msg.Result := HTCAPTION; end;