Microsoft Office Tutorials and References
In Depth Information
Setting Up Your Own Main-Menu Form
forms, print reports, and run queries. The most useful Command Button
Wizard choices for buttons on a main-menu form are
Open Form (in the Form Operations category): Opens any other form.
Preview Report (in the Report Operations category): Opens a report in
Print Preview.
Print Report (in the Report Operations category): Prints a report
without previewing it.
Run Query (in the Miscellaneous category): Runs an action query or
opens a select query in Datasheet view.
Run Macro (in the Miscellaneous category): Runs a macro. The macro
needs to exist before you create the command button.
If you want to do something else, you need to create a submacro in your
macro and then tell the command button to run it. The next two sections
describe both ways to make a command button: letting the Command
Button Wizard write an embedded macro for your button and writing your
own macro for the button.
Letting the wizard make your command button
If the Command Button Wizard knows how to write the embedded macro
for your button, use the wizard. Book IV, Chapter 3 describes how to tell the
Command Button Wizard what you want the button to do.
Open your main-menu form in Design view, and follow these steps:
1. Click the Button button in the Controls group on the Design tab of the
Ribbon and then click the form where you want the button to appear.
Access starts the Command Button Wizard. (See Book IV, Chapter 3 for
the details.)
2. Select the category and action for what you want the button to do, and
click Next.
Depending on which action you choose, the wizard asks for specific
information about what you want to do. If you choose Open Form as the
action, for example, the wizard asks which form you want to open and
whether you want it to display all or specific records.
3. Answer the wizard’s questions about what form you want to display,
what report you want to preview or print, and what query you want to
open or run; then click Next.
4. When the wizard asks what the button should look like, click Text
or Picture, specify the text or icon to appear on the button, and then
click Next.
Search JabSto ::

Custom Search