Delphi-PRAXiS
Seite 2 von 2     12   

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   GUI-Design mit VCL / FireMonkey / Common Controls (https://www.delphipraxis.net/18-gui-design-mit-vcl-firemonkey-common-controls/)
-   -   Delphi Form per Code erstellt - Minimiert öffnen? (https://www.delphipraxis.net/79446-form-per-code-erstellt-minimiert-oeffnen.html)

Yheeky 23. Okt 2006 20:07

Re: Form per Code erstellt - Minimiert öffnen?
 
Habe gerade einen Code gefunden, aber hier hätte ich mal gerne nach einer Erklärung gefragt:

Delphi-Quellcode:
  SetWindowLong(Form2.Handle, GWL_EXSTYLE, GetWindowLong(Form2.Handle, GWL_EXSTYLE) or WS_EX_APPWINDOW and not WS_EX_TOOLWINDOW);
ShowWindow(Form2.Handle, SW_ShowMinimized);
//Form2.Show;
Bei diesem Code klappt alles soweit, nur lässt sich die Form nicht schließen :roll:

Bei folgendem Code funktioniert alles:

Delphi-Quellcode:
  SetWindowLong(Form2.Handle, GWL_EXSTYLE, GetWindowLong(Form2.Handle, GWL_EXSTYLE) or WS_EX_APPWINDOW and not WS_EX_TOOLWINDOW);
ShowWindow(Form2.Handle, SW_ShowMinimized);
Form2.Show;
Warum nochmal das Form2.Show? Was bewirkt das?


Alle Zeitangaben in WEZ +1. Es ist jetzt 22:15 Uhr.
Seite 2 von 2     12   

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz