|
|
|
|
|
- Overview
- Handling the tabs of a Sidebar control
- Changing the active tab
- Getting the active tab
- WLanguage functions for manipulating Sidebar controls
- Properties specific to the tabs of a Sidebar control
Manipulating Sidebar controls programmatically
WINDEV and WINDEV Mobile allow you to manipulate Sidebar controls programmatically. To do so, use the variable of the Sidebar control in the code. The variable in the Sidebar control field corresponds to the number of the active pane.. This variable is an integer. Remark: WINDEV and WINDEV Mobile manage the passage automatically when the user clicks on a shutter. Handling the tabs of a Sidebar control To handle a tab, use the following syntax: <Champ Boîte à outils>[Numéro du volet].NomPropriété = ValeurPropriété For example: BAO_MaBoîte[2].Etat = Grayed
Tab 1 (tab at the top) is enabled by default. The active tab can be changed programmatically. To enable a sidebar tab: - Specify the number of the tab to be enabled:
<Champ Boîte à outils> = <Numéro du volet> - Use the Value property.
The number is assigned during the pane description: in the list of panes, the first one is number 1, the second one is number 2, and so on Remarks: - If the specified tab does not exist, the displayed tab does not change.
- On a single sidebar, only one tab can be displayed at a time.
- When changing to another tab:
- the output code of the field in focus is executed.
- the entry code of the first editable control in the tab is enabled.
To retrieve the number of the active tab: - perform a simple assignment. For example:
<Numéro du volet actif> = <Champ Boîte à outils> - use the Value property.
WLanguage functions for manipulating Sidebar controls The following functions are used to manage the characteristics of Sidebar controls. | | ControlClone | Clones a control by associating it with a tab of a Sidebar control. | EnumControl | Lists the controls associated with a Sidebar control. | EnumSubElement | Lists the tabs of a Sidebar control. |
Properties specific to the tabs of a Sidebar control The following properties can be used to programmatically manipulate tabs in Sidebar controls. | | Count | Gets the number of tabs of a Sidebar control. | Image | Gets and sets the image associated with a tab of a Sidebar control. To handle the tab, use the following syntax: <Sidebar control> [<Tab index>]. |
For a complete list of WLanguage properties that can be used with Sidebar controls, see Properties associated with a sidebar.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|