ACC1x: How to Run MS Access Wizards or Open the WIZARD.MDA File

ID: Q104569


The information in this article applies to:
  • Microsoft Access versions 1.0, 1.1


SUMMARY

You can cause the Microsoft Access Wizards to run by calling the zwWizMain() function that is defined in the zwUI module of the WIZARD.MDA file.


MORE INFORMATION

The zwWizMain() function is declared as

Function zwWizMain (<szTable> As String, ByVal <fReport> As Integer)

where <szTable> is a string value that is the name of an existing table or query in the open database, and <fReport> is a Boolean value. The value for <fReport> is either 0 or 1. Zero will open the FormsWizard, and 1 will open the ReportWizard.

You can also open the WIZARD.MDA file in Microsoft Access in order to view the code used by the FormsWizard and ReportWizard. To open the WIZARD.MDA file, do the following:
  1. While Microsoft Access is not running, open the MSACCESS.INI file located in your Windows directory. You can use any text editor (for example, the Microsoft Windows Notepad editor) to open the MSACCESS.INI file.


  2. Locate the [Libraries] section in the file. It should look like:

    [Libraries]
    wizard.mda=ro


  3. Comment out the "wizard.mda=ro" line by putting a semicolon at the beginning of the line. The section should now look like:

    [Libraries]
    ;wizard.mda=ro


  4. Save and close the MSACCESS.INI file.


  5. Start Microsoft Access.


  6. From the File menu, choose Open Database.


  7. Select the WIZARD.MDA file in the Open Database dialog box.


With the WIZARD.MDA file open, you can view the code used by the Wizards. The following example demonstrates how to call the zwWizMain() function from an Immediate window:

   ?zwWizMain ("My Table", False) 

NOTE: You will not be able to run the Wizards as you would normally while the WIZARD.MDA file is open. To run the Wizards normally, you need to remove the change made to the MSACCESS.INI file in step 3 above, and then restart Microsoft Access.

Additional query words: zwinitwizard

Keywords : kbprg MdlLib
Version : 1.0 1.1
Platform : WINDOWS
Issue type : kbhowto


Last Reviewed: March 26, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.