Microsoft KB Archive/248898

From BetaArchive Wiki

Article ID: 248898

Article Last Modified on 11/25/2002


  • Microsoft Access 2000 Standard Edition

This article was previously published under Q248898

Advanced: Requires expert coding, interoperability, and multiuser skills.

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


If you have opened multiple instances of a report, you find that no matter which instance you try to export or e-mail, the earliest instance remaining open is always saved or sent. This happens no matter which format you choose for the export.


For these actions, Access only recognizes the earliest instance of the report.


To resolve this problem, obtain Microsoft Office 2000 Service Release 1/1a (SR-1/SR-1a).

To obtain SR-1/SR-1a, click the article number below to view the article in the Microsoft Knowledge Base:

245025 OFF2000: How to Obtain and Install Microsoft Office 2000 Service Release 1/1a (SR-1/SR-1a)

To temporarily work around this problem, do the following. If you want to send or save the second or later instance of a report, close the earlier instances. For example, if you have four instances of a report open, and you want to save the third one to a snapshot, close the first and second instances of the report. If you then also wanted to save the fourth instance of a report, first close the third instance.


Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article. This problem was corrected in Microsoft Office 2000 SR-1/SR-1a.


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.

Steps to Reproduce Behavior

  1. Open the sample database Northind.mdb.
  2. In the Database window, click Reports under Objects, and then click Create report by using wizard.
  3. On the first Report Wizard page, click Table:Orders in the Tables/Queries list.
  4. In the Available Fields list, click OrderID, CustomerID, and EmployeeID and move these fields to the Selected Fields list.
  5. On the next page of the wizard, you do not need any grouping, so click the left arrow (<) in the center of the dialog box, so that the three fields appear as follows in the preview pane:

    OrderID, CustomerID, EmployeeID

  6. Click Finish. A new Orders report appears in Print Preview.
  7. On the View menu, click Design View.
  8. On the View menu, click Properties.
  9. Click the Data tab, and delete Orders from the RecordSource property.
  10. Close the Properties dialog box.
  11. On the View menu, click Code.
  12. For the Report_OnOpen event procedure, type the following code:

    Private Sub Report_Open(Cancel As Integer)
        Me.RecordSource = _
        "Select * from Orders where EmployeeID = " _
        & Forms!Test1.ActiveControl.Column(0)
    End Sub
  13. Save the report as EmpOrders.
  14. Create the following form not based on any table or query:

       Form: Test1
       Caption: TestForm
       Combo box
       Name: RunReport1
       Row Source Type: Table/Query
       Row Source: SELECT [Employees].[EmployeeID], 
                   [Employees].[FirstName] FROM [Employees]
       Bound Column: 1
       Column Count: 3
       Column Widths: 0";1";0"
       Combo box
       Name: RunReport2
       Row Source Type: Table/Query
       Row Source: SELECT [Employees].[EmployeeID], 
                   [Employees].[FirstName] FROM [Employees]
       Bound Column: 1
       Column Count: 3
       Column Widths: 0";1";0"
  15. On the View menu, click Code.
  16. Type the following code:

    Option Compare Database
    Dim rpt1 As Report
    Dim rpt2 As Report
    Private Sub RunReport1_BeforeUpdate(Cancel As Integer)
       Set rpt1 = New Report_EmpOrders
       rpt1.Visible = True
    End Sub
    Private Sub RunReport2_BeforeUpdate(Cancel As Integer)
       Set rpt2 = New Report_EmpOrders
       rpt2.Visible = True
    End Sub
  17. Save the code, close the module, and return to the form.
  18. Run the form, and then in the RunReport1 combo box list, click Peacock. The first instance of the report appears. You see all of the orders handled by Peacock. Do not close the report.
  19. Return to the form, and then in the RunReport2 combo box list, click Fuller. The second instance of the report appears. You see all of the orders handled by Fuller.
  20. With the second instance of the report active, click Export on the File menu.
  21. In the Save as type box, click Snapshot Format. Click Save.

Note that in the Snapshot Viewer you see the data from the first report. You see Peacock instead of Fuller.

Additional query words: pra excel rich text format html xls rtf htm txt snp

Keywords: kbbug KB248898