- Get Northwind database:
- Navigate to the Northwind.mdb database in the Samples subfolder of your Microsoft Office folder.
- Copy Northwind.mdb to the Clipboard and paste it in another folder.
- Rename the file CopyOfNorthwind.mdb, which you can now open and use without changing the original file.
- Find the Table on which to base the form:
- From the CopyOfNorthwind Database window, click Tables from the list on the left and click Suppliers from the pane on the right.
- When the Suppliers Table appears on-screen, review its fields. Let’s assume that you rarely need to change or use a supplier’s street address; in that case, a form that uses tabbed pages could be an effective way to present supplier information. You could place the fields you use regularly (such as contact name and phone number) on one page and move the other fields (such as address) to another page.
- Close the Suppliers Table.
- With the Suppliers Table still selected in the CopyOfNorthwind Database window, open the Insert menu and choose Form.
- In the New Form dialog box, select Design View and click OK.
- Maximize the window and make sure the Suppliers field list and the Toolbox are in view (if not, select them from the View menu).
- Create tabbed the form:
- Click the Tab Control tool from your Toolbox, and when the symbol appears, drag it to the top left corner of the form; two or three rows of dots from the top of your form, draw a rectangle about 4 inches wide x 2 inches long and release your mouse button.
- The new tab control will display with two tabbed pages, labeled as Page 1 and Page 2.
- Give these tabbed pages meaningful names
- Right-click the page on the left, click Properties, and choose the Other tab.
- Select the text in the Name property field and type Contact Info.
- Go back to the new tab control and click the tab of the page on the right.
- In the Name property field, type Street Address and press ENTER.
- Add Fields To Tabbed Pages:
- Click the Contact Info page.
- In the Suppliers field list, select CompanyName and drag and drop it to about 1 inch from the left and 0.5 inches from the top.
- Back on the new tab control, click the Street Address tab.
- In the Suppliers field list, select Address and drag and drop it to 1 inch from the left and two rows of dots from the top.
- Next, select City from the Suppliers field list and drag and drop it to 1 inch from the left and two rows of dots underneath the Address field.
Working with Tabbed Forms:
- Change Page Order: Right-click any open area on the tab control and choose Page Order. In the dialog box, use the Move Up and Move Down buttons to change the page order.
- Add Or Delete A Page: The Add Page and Delete Page commands are available from the property sheets of both the individual tabbed page controls and the tab control as a whole. Use the Add Page command to add a new page to the right of existing pages; use the Delete Page command to delete the active page.
- Change The Dimensions Of A Tab Control: Select the tab control and use the size handles to change the dimensions. You also can open the Tab Control property sheet and edit the Width and Height property fields on the Format tab.
- Change The Font Of The Tab Text: On the Format tab of the Tab Control property sheet, you can edit Font Name, Font Size, etc. You cannot, however, set different fonts for different pages.