Built-In Objects and Collections
A toolbar allows the user to perform some actions faster than using the main menu. Because of space restrictions, a toolbar usually makes available only the most regularly performed actions. These actions are presented as buttons with (small) icons. When Microsoft Access opens, it displays one toolbar called Database. If you open a new object such as a table or a form, a new toolbar adapted to it would display. In some cases, for example if you are working on a form or a report, Microsoft Access may display more than one toolbar.
In most cases, the toolbars that Microsoft Access will be enough for the user to perform all necessary operations of a regular database. If not, you can create a new toolbar. You can create one based on the existing toolbar items of Microsoft Access or you can create a new one with buttons that don't exist already and whose behavior is not yet defined.
To start a new toolbar, on the main menu of Microsoft Access, you can click Tools -> Customize... You can also click View -> Toolbars -> Customize... Or, you can right-click the main menu or an existing toolbar and click Customize... To create a new toolbar in the Customize dialog box, in the Toolbars property page, click New... When the New Toolbar dialog box opens, in its Toolbar Name text box, type a name for the new toolbar and click OK. This would display a new empty toolbar.
To add the buttons to the new toolbar:
The existing toolbar buttons (and menu items) of Microsoft Access are available in the Customize dialog box. To use one of these, in the Categories list of the Commands property page, click a group. In the Commands list, drag the desired item and drop it in your toolbar. If you don't know what a button is used for, click it and click Description. A tool tip would give a short description of the menu item.
To create a button that is not part of the existing built-ins of Microsoft Access, in the Categories list of the Commands property page of the Customize dialog box, click File. From the Commands list, drag Custom and drop it in your toolbar. By default, the new button would be added as text. If you want to use an icon on the button, right-click the new button. To use an existing icon, position the mouse on Change Button Image and click one of the available icons. If none of the icons suits you, click Edit Button Image instead. In the Button Editor dialog box, use the colors in the Colors section and draw the boxes in the Picture section. After designing or customizing the icon, click OK. If you want only the icon to display on the button without the accompanying text, right-click the button in your toolbar and click Text Only (In Menus).
After creating a tool bar, click Close on the Customize dialog box. To display the toolbar when a certain form or report comes up, first open the form or report in Design View and access its Properties window. In the Other property page of the Properties window, set the Toolbar property to your toolbar.
A menu bar is a list of actions that can be presented to the user, as a window, so the user can selection what action to perform at a particular time. An example of a menu bar is the main menu that displays under the title bar of Microsoft Access. While Microsoft Access always displays its built-in menu, you too can create a menu bar to display when necessary. Like many other objects we will review here, a menu bar is an object of type Command Bar.
A menu bar is referred to as main menu when it presents the most routine operations of a database and it typically displays in the top section of the main window of an application. The main menu is usually made of categories of items. When the user clicks a word on the group, a column of actions displays, allowing the user to make a selection. In most cases, you can let the user use the default menu bar provided by Microsoft Access. If not, you can create a menu based on the existing menu items of Microsoft Access. In unusual cases, you can create a new menu.
Probably the easiest way to get a new menu is by creating one using the available items from Microsoft Access. To do this, you can right-click the existing menu of Microsoft Access and click Customize, or, on the main menu of Microsoft Access, you can click Tools -> Customize... Alternatively, on the main menu of Microsoft Access, you can click View -> Toolbars -> Customize...
To create a new menu bar in the Customize dialog box, in the Toolbars property page, click New... This would open the New Toolbar dialog box that allows you to specify a name for the new menu. After specifying the name, click OK. Once you click OK, a new bar would come up. To indicate that you want to create a menu bar (and not a toolbar), in the Toolbars property page of the Customize dialog box, click the name of your new menu and click Properties. In the Toolbar Properties dialog box, change the Type combo box to Menu Bar.
To add the desired actions:
If you use an existing menu item from Microsoft Access' main menu or a menu item form the Commands list of the Commands property page of the Customize dialog box, the action would be defined already and you can use it. When selecting such a menu item, if you don't know what it is used for, click it and click Description. A tool tip would give a short description of the menu item.
If none of the existing menu items does what you want, you can create a new menu item as you wish. To do this, in the Categories list of the Commands property page, click File. In the Commands list, drag Custom and drop it in your menu bar. While the new menu item is still selected in your menu bar, in the Commands property page of the Customize dialog box, click Modify Selection. In the Modify Selection menu, change the Name as you wish.
By default, some existing menu items of Microsoft Access are equipped with an icon. If you select one of these, its icon would be added also. If you create your own menu item independent of any existing menu item, it would not have an icon. If you are using an existing menu item that has an icon but you don't want the icon to display, you can right-click the menu item and click one of the Text Only options. Whether you are using an existing menu item that has an icon or you are using a new menu item that doesn't have an icon, to use a new or a custom icon on a menu item, right-click it in your menu bar. In the menu that appears, position the mouse on Change Button Image and select one from the list. If none of the icons suits you, click Edit Button Image... A Button Editor dialog box would come up where you can demonstrate your artistic capabilities to create a small icon. After designing or customizing the icon, click OK. The icon would be associated with the menu item.
After creating the menu bar, click Close on the Customize dialog box. To make sure that the new menu would display when a certain form of your database displays, you must assign it to that form. To do this, first open the form in Design View and access its Properties window. Then, set its Menu Bar property to your custom menu bar. When you switch the form to Form View, the designed menu bar would display.
A shortcut menu is one that is associated with a particular window, object or view of an object. By tradition, this menu is made to display when the user right-clicks a certain window, object, or area of an application. If you right-click a table or a form in Microsoft Access, you would see an example of a shortcut menu.
Microsoft Access ships with various shortcut menus that display depending on the object on the screen. As we will see when studying data analysis, an example of a shortcut menu appears when the user right-clicks a table or a form and allows to user to perform valuable data analysis. As mentioned for the main menu, the built-in shortcut menus of Microsoft Access will be enough in most cases. If you want, you still can create your own shortcut menu or customize those that ship with Microsoft Access.
A shortcut menu is normally made of only one column of menu items. You create it using the same approach you would for a main menu except that you should create only one group. To indicate that you are creating a shortcut menu, select its name in the Toolbars list of the Toolbars property and click Properties. In the Toolbar Properties dialog box, set its Type to Popup.
After creating shortcut menu, to make it available to the user, you should associate it with the desired object of your application. For example, you can first display a form in Design View, click an existing control on it. Then, in the Properties window, set its Shortcut Menu Bar to your custom shortcut menu.
As repeated a few times. Microsoft Access provides, in its menus and toolbars, all the necessary tools a user would need to perform all routine operations on a database. If you decide to create your own menus or toolbars, there are still details you should be aware of.
If you decide to provide a custom main menu to your application, you should make it as necessary as possible. You should make sure that it allows the user to close the database, unless you explicitly don't want the user to be able to close the database. You should make your menu appear as much as possible as Microsoft Access', following the recommendations of Microsoft standards. For example, if the main menu has a File and a Help menus, the File group should be the most left and the Help menu should be the most right.
If you decide to display a toolbar when a form or report comes up, you should make sure the toolbar provides all necessary operations.
|Home||Copyright © 2005-2010 FunctionX, Inc.|