Printer settings saved when edited in Preview mode in Access 2002 (282363)



The information in this article applies to:

  • Microsoft Access 2002

This article was previously published under Q282363
Moderate: Requires basic macro, coding, and interoperability skills.

This article applies to a Microsoft Access database (.mdb) and to a Microsoft Access project (.adp).

SYMPTOMS

In Design view, changes to the Printer properties are automatically saved with a form if the form is saved before it is closed. Conversely, although changes made in Browse view or Print Preview should not be saved, these changes may, in fact, be saved unexpectedly.

RESOLUTION

To work around this issue, manually reset the Printer properties; to do so, follow these steps:
  1. Open the form in Preview mode.
  2. On the File menu, click Page Setup.
  3. In the Page Setup dialog box, on the Page tab, click Portrait or Landscape. Select a Paper Size and Source setting, and then select the printer that you want to use. Click OK.

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

MORE INFORMATION

Steps to reproduce the problem

CAUTION: If you follow the steps in this example, you modify the sample database Northwind.mdb. You may want to back up the Northwind.mdb file and follow these steps on a copy of the database.

  1. Open the sample database Northwind.mdb or the sample project NorthwindCS.adp.
  2. Open the Customers form in Form view, and then on the File menu, click Print Preview.

    Note that the form is displayed in Portrait orientation.
  3. Close the Customers form.
  4. Type the following code in a new module:
    Sub Test()
       Dim frm As Access.Form
       Dim ptr As Access.Printer
       DoCmd.OpenForm "Customers", acPreview
       Set frm = Forms!Customers
       Set ptr = frm.Printer
       ptr.Orientation = acPRORLandscape
    End Sub
    					
  5. On the Run menu, click Run Sub/UserForm.

    Note The Customers form opens in Landscape orientation. Close the Customers form.
  6. On the File menu, click Print Preview. Note that the form is saved in Landscape orientation.

Modification Type:MinorLast Reviewed:10/11/2006
Keywords:kbbug kbfix KB282363 kbAudDeveloper