X web hosting - CHAPTER 4 WORKING WITH REALBASIC MENUS Accelerator
CHAPTER 4 WORKING WITH REALBASIC MENUS Accelerator keys are identified by the presence of an underscore character somewhere in the text of the menu, submenu, or menu item. For example, the letter F is generally used as the accelerator key for the File menu and is displayed as File. When the user presses the Alt key, and then presses the F key, an application displays the contents of its File menu. Once displayed, the user can access any of the submenus of menu items located under that menu by continuing to press the Alt key, and then press the accelerator key assigned to the submenu or menu item. Using accelerator keys, a user may access any part of an application s menu system without ever touching their mouse. Figure 4-18, shows how accelerator keys are implemented in a typical Windows application. Figure 4-18. Examining the accelerator key provided on the File menu of Microsoft s Notepad application Accelerator keys are specified by placing an ampersand (&) character in the Text property belonging to a menu, submenu, or menu item. For example, to assign an accelerator key of B for a menu item that has a Text value of Background, you would place the ampersand character just at the beginning of the word, as the following shows. 1. Finish building the menu system for your REALbasic application. 2. Select the menu where the menu items reside. 3. Select the menu item and locate its Text property. 4. Add the ampersand (&) character to the beginning of the specified value. 5. Press Enter or Return. The results should be immediately visible. Using Menu Items to Trigger Command and Code Execution Once you finish putting together your application s menu system, you need to associate program code statements with each menu item to make the menu functional. Users can then activate menus and execute associated programming statements by clicking the appropriate menu item.
We recommend you use shared web hosting services, because many users agree that it is cheap, reliable and customer-satisfying webhost.