DelphiFAQ Home Search:
General :: Programming :: Delphi :: VCL
About the Delphi VCL (Visual Component Library)

Articles:

This list is sorted by recent document popularity (not total page views).
New documents will first appear at the bottom.

Only the 40 most recently viewed articles are shown.
You can see the full list here.

Featured Article

Change the Window Style for a control

The CreateParams method is used to set up the window style and all the other arguments
that are passed to CreateWindowEx to create the control's
To change the window style use something like this which creates a window with or
without a vertical scroll bar.

procedure TMyControl.CreateParams(var Params: TCreateParams) ; 
 begin 
   inherited CreateParams (Params) ; 
   if IWantAScrollBar then 
     Params.Style := Params.Style or WS_VSCROLL 
   else 
     Params.Style := Params.Style and not WS_VSCROLL ; 
 end;

Generated 8:01:57 on Dec 19, 2018