This is the legacy 4D documentation web site. Documentations are progressively being moved to developer.4d.com

Home

 
4D v20 R7
Hierarchical Pop-up Menus and Hierarchical Lists

Hierarchical Pop-up Menus and Hierarchical Lists  


 

 

A hierarchical pop-up menu has a submenu associated with each item in the menu. Here is an example of a hierarchical menu:

Similarly, a hierarchical list has a sublist associated with each item in the list. Here is an example of a hierarchical list:

Note: In forms, hierarchical pop-up menus are limited to two levels. However, objects of the hierarchical list type are not limited.

You can expand or collapse the hierarchical list by clicking on the triangular icons.

You can control whether an item in a hierarchical list can be modified by the user. If an item in a hierarchical list is modifiable, the user can edit it by using the Alt+click (Windows) / Option+click (under Mac OS) shortcut, or by carrying out a long click on the text of the item. If you populate a hierarchical list using a list created in the Lists editor, you control whether an item in a hierarchical list is modifiable using the Modifiable Element option in the Lists editor. For more information, see Setting list properties.

You manage hierarchical pop-up menus and hierarchical lists using the Hierarchical list commands in the language. The principle consists in assigning the hierarchical list reference to the variable associated with the object in the Form editor. For more information, see the Hierarchical Lists chapter of the 4D Language Reference manual.

You can also associate hierarchical list references with form object choice lists (sources, required values and excluded values) using the OBJECT SET LIST BY REFERENCE or OBJECT SET LIST BY NAME command.

You can assign standard actions to Hierarchical Pop-up Menu objects (“Action” theme of the Property List). Only actions that display a sublist of items are supported by this object.

For example, you can assign the "backgroundColor" standard action to a hierarchical pop-up menu: at runtime the object will display an automatic list of of background colors. You can can override the automatic list by assigning an additional Choice list to the object, in which each item has been assigned a custom standard action.

For more information, please refer to the Standard actions section.

 
PROPERTIES 

Product: 4D
Theme: Working with active objects

 
PAGE CONTENTS 
 
HISTORY 

Modified: 4D v16 R4

 
ARTICLE USAGE

4D Design Reference ( 4D v20 R7)