<< Click to Display Table of Contents >>
SetFrameOptions |
SetFrameOptions(Title, [Flags])
This method is used to configure a Frame's title on a window and that window style. The Title parameter is a String that contains window's title. This text is displayed if Screen's Caption property is empty.
The Flags parameter specifies window's style. If this parameter is omitted, its default value is -1 (minus one). This value is used to keep window's previous configuration. When this value is not -1 (minus one), users can change window's style by specifying a sum of values of all combinations described on the next table.
Possible combinations for the Flags parameter
Value |
Description |
---|---|
1 |
Enables a title bar on this window |
2 |
Enables a Close button on this window |
4 |
Enables a Minimize button on this window |
8 |
Enables a Maximize button on this window |
16 |
Enables a border on this window |
32 |
Specifies that this window can be resized. To do so, this window must have a border |
64 |
Specifies that this window can be moved |
256 |
Specifies that this window stays on top of a Screen |
512 |
Specifies that this window is configured in a Tool Bar style |
1024 |
Disables object buttons |
2048 |
Centers this window |
Example:
Sub Screen_OnPreShow()
Frame.SetFrameOptions("Alarm Screen", 114)
End Sub
In the previous example, the value 114 (2 + 16 + 32 + 64) indicates that this window contains a Close button enabled (2), a border (16), can be resized (32), and can be moved (64). This window's title is "Alarm Screen".
In the Open Screen and Open Modal Screen Picks, users can also configure a window style during edition, by using the Window Style dialog box. For more information, please check topic Picks.
NOTE |
This method must be used after calling the SetDisableTaskSwitching method, if users want to change window's title or style. |