🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.lang.pascal.delphi.misc
2 messages
2 total messages Started by tdj Thu, 18 Jun 1998 00:00
How to disable Window's moving & resizing?
#129
Author: tdj
Date: Thu, 18 Jun 1998 00:00
28 lines
1422 bytes
Hello,

In Delphi, how can I make a Window

- run in full screen mode
- no resizing
- cannot be moved ?

I have tried to set

  WindowState=maximize

However the window will still be "restored" to a "normal" Window when double
click on the Window Title. Once it is a normal window,	the user can move the
Window around by using the mouse cursor.

Any suggestion will be very appreciated.

Thanks

Ted.




-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/   Now offering spam-free web-based newsreading
Re: How to disable Window's moving & resizing?
#130
Author: Francois Labonte
Date: Thu, 18 Jun 1998 00:00
50 lines
2111 bytes
Hi Ted. First, put your WindowState to maximize and then try:
...
  private
    { Private declarations }
  Done : Boolean;
  Procedure WMWindowPosChanging(Var Msg: TWMWindowPosChanging); Message
WM_WindowPosChanging;
...
procedure TForm1.FormActivate(Sender: TObject);
begin
Done := True;
end;
...
Procedure TForm1.WMWindowPosChanging;
Begin
If Done Then
  Msg.WindowPos^.Flags := Msg.WindowPos^.Flags or SWP_NOMOVE or SWP_NOSIZE;
End;


Hope this helps

\Francois


> Hello,
>
> In Delphi, how can I make a Window
>
> - run in full screen mode
> - no resizing
> - cannot be moved ?
>
> I have tried to set
>
>   WindowState=maximize
>
> However the window will still be "restored" to a "normal" Window when double
> click on the Window Title. Once it is a normal window,  the user can move the
> Window around by using the mouse cursor.
>
> Any suggestion will be very appreciated.
>
> Thanks
>
> Ted.
>
> -----== Posted via Deja News, The Leader in Internet Discussion ==-----
> http://www.dejanews.com/   Now offering spam-free web-based newsreading
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads