How to Set / Remove the Form’s StayOnTop Style

Posted December 15th @ 8:58 pm by m3Rlin

To set or remove the form’s StayOnTop style you can just set the form’s FormStyle property. But this has side effects. For example: if you modify the form’s system menu using the Windows API. After the form’s style is changed the system menu will return to it’s normal state. You can get around this in [...]

How to Remove the Form’s Caption

Posted December 15th @ 8:57 pm by m3Rlin

You may have wanted to create a form that doesn’t have a caption bar, just like the one’s you may see in setup programs. Delphi VCL doesn’t give you but you can also use the Windows API
Just add this code to you form’s OnCreate method:

SetWindowLong(Handle, GWL_STYLE, GetWindowLong(Handle, GWL_STYLE) and not WS_CAPTION);
Height := Height - [...]

« Previous EntriesNext Entries »