ACC: Problems Outputting Report with Datasheet Form as Subreport

Last reviewed: February 13, 1998
Article ID: Q180458
The information in this article applies to:
  • Microsoft Access versions 7.0, 97

SYMPTOMS

Novice: Requires knowledge of the user interface on single-user computers.

If a report contains a form as a subreport, and the form is in Datasheet view, if you try to output the report to another file format such as text (*.txt), Microsoft Excel (*.xls), or rich text format (*.rtf) you may see the following unexpected behavior, depending on your version of Microsoft Access.

   In Microsoft Access 97
   ----------------------

   You receive the message

      Now outputting page <x> of
      '<reportname>' to the
      file '<outputfilepath>'

   where <x> is incremented indefinitely until you click Cancel. An output
   file is not created.

   In Microsoft Access 7.0
   -----------------------

   You receive the message

      The Save As command can't process any subforms contained in your
      report.
      Do you want to proceed anyway?

   When you click Yes, you receive the message

      Now outputting page <x> of
      '<reportname>' to the
      file '<outputfilepath>'

   where <x> is incremented indefinitely until you click Cancel. An output
   file is not created.

This behavior occurs regardless of the file format to which you output the report.

RESOLUTION

To work around this behavior, use the Save As Report option to save the form as a report before you output the report. To do so, follow these steps:

  1. In the Database window, right-click the form, and then click Save As Report on the menu that appears.

  2. In the Save Form As Report dialog box, type a name for the report, and then click OK.

  3. Open the main report in Design view.

  4. Right-click the control that contains the datasheet form, and then click Properties.

  5. Click the Data tab and change the source object from Form.<Formname> to Report.<Reportname>, where <Formname> is the name of the datasheet form and <Reportname> is the name of the report you saved in step 2.

MORE INFORMATION

Steps to Reproduce Behavior

  1. Open the sample database Northwind.mdb.

  2. In the Database window, click the Forms tab, and then click New.

  3. In the New Form dialog box, click AutoForm: Datasheet.

  4. In the drop-down list, click Shippers to base the form on the Shippers table, and then click OK.

  5. On the File menu, click Close. When you are prompted to save changes to the design of the form '<formname>', click Yes.

  6. In the Save As dialog box, type "frmShippers" (without the quotation marks), and then click OK.

  7. In the Database window, click the Reports tab, and then click New.

  8. In the New Report dialog box, click Design view, and then click OK to create a new, unbound report.

  9. On the Window menu, click Tile Vertically.

  10. In the Database window, click the Forms tab, and drag the frmShippers form to the Detail section of the new report.

  11. On the File menu, click Save As/Export.

  12. In the Save As dialog box, click "To an External File or Database," and then click OK.

  13. In the Save Report <reportname> dialog box, click Rich Text Format (*.rtf) in the Saved As Type list box, and then click Export.

    Note that you see the behavior described in the "Symptoms" section. You must click Cancel to dismiss the "Now outputting" message, and the output file is not created.


Additional query words: problem can't cannot
Keywords : FmsProb OtpProb
Version : WINDOWS:7.0,97
Platform : WINDOWS
Hardware : x86
Issue type : kbprb
Solution Type : Info_Provided


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: February 13, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.