Attach the
new menu and run the application
Where you are
Add menu scripts to
trigger user events
> Attach the new menu
and run the application
Now you attach the new sheet menu and run the application
again.
-
Double-click w_master_detail_ancestor in the System Tree.
If you cannot see the Properties view
Select View>Properties from the menu bar.
The menu listed in the MenuName box in the Properties view of
the Window painter is still m_pbtutor_sheet. -
Click the ellipsis button next to the MenuName box.
The Select Object dialog box displays.
-
Select m_my_sheet in the Menus list box and click OK.
This is the sheet menu you modified after inheriting it from
m_pbtutor_sheet. It is now listed as the menu name in the Properties
view. -
Click the Save button in PainterBar1.
Click the Run button in the PowerBar.
The application login window displays.
-
Type dba in the User ID box.
Type sql in the Password box and click OK.
The database connection is established, and the MDI frame for
the application displays. The File menu now includes a Report
cascading menu in place of the New menu item. The Open menu item is no
longer visible. -
Select File>Report>Maintain Customers from the menu
bar.Notice that a second toolbar appears and the Edit and Window
cascading menus include enabled menu items. -
Select the Edit menu.
The Edit menu has the Insert, Update, and Delete options you
added. These options do not function yet, because the DataWindow
controls in the Customer window do not have DataWindow objects
associated with them. -
Select the Window menu.
Notice that a new menu item has been added for the sheet you
just opened. -
Select File>Report>Maintain Products from the menu
bar.A second MDI sheet opens. This sheet cascades relative to the
first sheet. The menu bar does not change. That is because m_my_sheet
is the menu for both w_customers and w_products. -
Select the Edit menu.
Because the w_products window uses the m_my_sheet menu, the
Insert, Update, and Delete options are also available when the Product
window is open. -
Select the Window menu.
Another menu item has been added for the second sheet you
opened. The checkmark next to this menu item indicates that it is the
active sheet. -
Select File>Exit from the menu bar.
The application terminates and you return to the Window painter
workspace. -
Close the Window painter.