Selecting a dialog for editing, and linking dialogs with menus is achieved through the Select Dialog/Resource dialog. The dialog is available on the toolbar (SelectDlg), through the File menu (Select Dialog) or with the CTRL+D hot-key combination (in design mode, when the work dialog is visible).
The Select Dialog/Resource dialog looks like this:
Dialogs/Resources |
This control shows the dialogs and menus that comprise the project, in a tree-line list. Double clicking an item in the Dialogs/Resources tree will jump to the edit mode for that item (ie, the Menu Editor, etc). By single-clicking (selecting) an item, the various options for manipulating the item become available to the right, as follows: |
Open |
This opens the edit mode for the selected item in the Dialogs/Resources list. This is identical to double-clicking the item in the list. For a dialog, PowerBASIC Forms enters the design mode. Similarly, double-clicking a menu or accelerator table launches the Menu Editor. |
Close |
Dismisses the Select Dialog/Resource dialog and returns to the dialog design mode. |
Link |
The Link button is enabled only when there is at least one menu that is not attached (unlinked) to any dialog. Unlinked menus (and their associated accelerators) are always displayed under the item titled "<Resources Not Linked>". By performing a Drag+Drop operation on an unlinked menu, and dropping it onto a dialog that does not have an existing menu. Any associated accelerator table is automatically moved along with the menu. |
Unlink |
The Unlink button is used to unlink the highlighted menu from an associated dialog. The newly unlinked menu is moved to the "<Resources Not Linked>" item, and any associated accelerator table moves along with the menu. |
Delete |
Both dialogs and/or menus may be deleted from a project. Deleting a dialog will also destroy the menu and any accelerator table defined for that dialog. Deleting a menu will also remove the associated accelerator table. |
Accelerator tables are implicitly linked with a particular menu and cannot be independently moved. That is, when a menu is linked or unlinked from a dialog, the accelerator table will follow its associated menu. |
See Also