Press "Enter" to skip to content

How to Disable Menu Item in Oracle Forms?

You can disable a menu item in Oracle Forms in design time and at runtime. Design time you need to set enabled property manually for the menu and at runtime, you can disable the menu item using SET_MENU_ITEM_PROPERTY built-in. Below are the examples of both methods.

Steps To Disable Menu Item at Design Time

  1. Open the menu module in Oracle Forms.
  2. Expand the menu node and find the menu item you want to disable.
  3. Right click on the menu item and click on the Property Palette.
  4. In property palette window, under functional set the Enabled property to No.
  5. Save the menu and compile.

Now your menu item would be displayed as the disabled menu item.

Disabling Menu Item at Runtime

The following is the example of SET_MENU_ITEM_PROPERTY built-in to disable a sub-menu item on the When-New-Form-Instance trigger.

SET_MENU_ITEM_PROPERTY('department_record_menu.edit', ENABLED, PROPERTY_FALSE);

The department_record_menu is the parent item for edit menu. To disable the whole parent menu, specify the parent menu name only, as shown in the below example.

SET_MENU_ITEM_PROPERTY('department_record_menu', ENABLED, PROPERTY_FALSE);

See also: