The itemname() function returns the text value in a specified position in a menu or list field. List fields include list boxes, multi-select list boxes, combo boxes, drop-down lists, button drop lists and visual switches.


itemname([field|menu] name, position)


name – The name of the menu or list field for which you want to return the name of an item. The field must be a window field.

position – An integer indicating the numeric position of the text value you want to return. For list fields, 1 indicates the first position in the list. For menus, 1 indicates the first user-defined menu item. Grouped menu items that the application inherited, such as the Clipboard menu items Cut, Copy and Paste, are not counted.

Return value


Documentation Feedback