WINDEV Concepts

30 Part 1: Main concepts 11.3 Available features WINDEV allows you to: • Create a main menu. • Edit a main menu. • Delete a main menu. For more details, see the online help. Special case: Tool menu WINDEV allows you to automatically insert a "tool" menu ("?" type) in your application. On the "Window" tab, in the group "Bars and menus", expand "Main menu" and select "Add the "?" menu". 12 Menu options 12.1 Overview A menu (main menu or context menu) includes one or more options and sub-options. Each option runs a WLanguage code. In the editor, you can handle menu options in the same way for both main menus and custom context menus. To handle the menu options, simply edit the relevant menu. To edit (or display in the editor): • the main menu of a window: • open the relevant window in WINDEV. • select one of the menu options. The options and the sub-options are automatically displayed. • the custom context menu of a window: on the "Window" tab, in the "Bars and menus" group, expand "Popup menus" and select "<ContextMenuName>". 12.2 Handling menu options in the editor The window editor allows you to easily perform the following operations: • Add a menu option. • Add a separator. • Add a submenu. • Delete a menu option. The menu options can also be defined in the window editor, and their characteristics can be modified via a description window. The description window of the menu options allows you to: • change the option caption. • check or uncheck a menu option. • associate an image with a menu option. • associate a keyboard shortcut with a menu option. You also have the ability to associate a WLanguage code with a menu option. Only menu options without submenus can start a WLanguage process. For more details, see the online help. 12.3 Handling menu options programma- tically Options are manipulated in the same way in context menus and main menus. To programmatically manipulate a menu option, use the following syntax: • "<OptionName>" if the menu option is handled from the window. • "<WindowName>.<MenuName>.<Option Name>" if the option is handled from another window.

RkJQdWJsaXNoZXIy NDQ0OA==