|
|
Locking controls
TFormDesigner allows to lock some controls to prevent them from changing their size and position. Locked control can be selected, but cannot be moved/resized. To lock control just add the control's name into the LockedControls list. There are three ways to do it:
At design time:
- Double-click the LockedControls property in the Delphi/C++ Builder Object Inspector and add the needed names
- Double-click TFormDesigner component and use the component editor
At runtime:
- Add the needed names into LockedControls list directly. ProtectedControls is a TStrings type, so just use the Add method.
FormDesigner1.LockedControls.Add('Button1');
|
|