KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Determining what tab is clicked in tab control
PRODUCT: 4D | VERSION: | PLATFORM:
Published On: April 23, 1999
Your current browser may not allow you to download the asset. We recommend Mozilla Firefox or Google Chrome.
Log In

The way of determining what tab the user clicked on in a tab control differs depending on how a Tab Control is defined.
If a Tab Control is define via the "Edit String" button or as a text array, it is possible to just reference the list itself. In the following code, the Tab_Control will return a long integer with the number of the tab the user clicked on.

If a Tab Control is a defined via a Choice List or references a Hierarchical List, it will always return it's reference number. To return the number of the tab the user clicked on requires the use of the "Selected list item" function. For example, the code below will return the tab the user clicked on.

For more information on the subject of Tab Controls refer to