Release 10.1A: OpenEdge Development:
Progress 4GL Handbook

> ## Creating a dynamic menu

> This final section shows you how to create a dynamic menu for a window. Dynamic menus share the same characteristics of static menus. As with other dynamic objects, you use `CREATE` statements rather than `DEFINE` statements to create a menu, submenu, or menu item. You parent these objects together in a hierarchy by setting their `PARENT` attribute. If you need to delete a dynamic menu before its widget pool is deleted, you use the `DELETE OBJECT` statement to delete the top-level menu object. Progress automatically deletes all its child submenus and menu items.

> When you define a static menu, you need to define its elements in reverse order, so that you define the submenus before you reference them in the static `DEFINE MENU` statement. With dynamic menus you do the opposite. You first define the top-level menu, then its submenus, and then each submenu’s menu items. As you create each one, you parent it to the next level up to establish the menu hierarchy.

Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095