Access appears to hang when you preview or print an object in PivotTable view (282315)



The information in this article applies to:

  • Microsoft Office Access 2003
  • Microsoft Access 2002

This article was previously published under Q282315
Novice: Requires knowledge of the user interface on single-user computers.

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

SYMPTOMS

When you preview or print an object in PivotTable view, you receive the following message:

Previewing or printing this PivotTable view might take a long time because it displays a large amount of detail data. Microsoft Access might not respond for some time.
Do you want to continue?
* To reduce the amount of time required, hide most or all of the detail data in the view.

* For more information, consult the Microsoft Knowledge Base article Q282315.

After you click OK, Microsoft Access appears to stop responding (hang). However, after a significant wait, the object is successfully displayed in preview or is printed.

CAUSE

The PivotTable is displaying a large amount of detail data.

RESOLUTION

There are two approaches for working around this behavior. You can either reduce the amount of detail data being displayed in the PivotTable, or you can use a different view if you need to preview or print many detail records.

Reducing the Amount of Detail Data Displayed

You can reduce the amount of detail data being displayed by viewing only the summary data, and then drilling down to see specific details as needed. The following steps demonstrate how to build a PivotTable that displays only summary data, and how to drill down to see specific details for printing:
  1. Open the sample database Northwind.mdb.
  2. Open the Orders table in Datasheet view.
  3. On the View menu, click PivotTable View.
  4. Drag the CustomerID field from the PivotTable Field List to the "Drop Row Fields Here" drop area. This displays the data from the CustomerID field down the left side of the PivotTable.
  5. Expand the Order Date by Month fieldset in the PivotTable Field List.
  6. Drag the Months field from the PivotTable Field List to the "Drop Column Fields Here" drop area. This displays the months of the years across the top of the PivotTable.
  7. Drag the Freight field from the PivotTable Field List to the "Drop Totals or Detail Fields Here" drop area. This displays the detail data from the Freight field at the intersection of each row and column.
  8. Click the Freight column heading under the first month. This should select all the cells in all the columns where there is a value.
  9. On the PivotTable menu, point to AutoCalc, and then click Sum. Note that the PivotTable displays a total of Freight for each customer in each month.
  10. On the PivotTable menu, click Hide Details. Note that this hides all details, and shows just the summary data.
  11. Double-click one of the cells that contains a value, such as the total for ERNSH in November. Note that only the specific details for this total are shown, as opposed to all details.
  12. On the File menu, click Print Preview.
Note that the object is immediately displayed in Print Preview mode.

Reducing the Amount of Data Displayed by Using a Filter

You can also reduce the amount of data that is currently displayed in the PivotTable by applying a filter. To reduce the amount of data that is displayed in the PivotTable by applying a filter, follow these steps:
  1. Follow steps 1 through 7 in the "Reducing the Amount of Detail Data Displayed" section earlier in this article.
  2. Click the arrow in the CustomerID column in the PivotTable, and then click to clear the (All) check box, so that no items are currently selected (checked).
  3. Click to select the check boxes next to "BERGS" and "BLONP", and then click OK. This filters the PivotTable to only display orders for these two customers.
  4. On the File menu, click Print Preview.
Note that the object is immediately displayed in Print Preview mode.

Switch to a Different View Before Previewing or Printing

If you need to display a large amount of detail data while you preview or print the object, switch the object to another view, such as Datasheet view or Form view. These views do not use the PivotTable component, and are not subject to its limitations when printing.

STATUS

This behavior is by design.

MORE INFORMATION

PivotTable views are designed for summarizing and analyzing data, while at the same time giving you the ability to drill down to view detail data. For example, if you notice something interesting about a particular summarization, you can drill down and view specific details. PivotTable views are not optimized for displaying and printing many detail records at once.

When you view detail data in a PivotTable, the number of visible cells greatly increases. In order to display the contents of each cell, the PivotTable component generates a separate ADO recordset for each cell in the PivotTable. As the number of cells that are displayed in the PivotTable increases, so does the number of ADO recordsets that the PivotTable component must open and manage. This results in a longer time to preview or print the PivotTable.

Even though previewing or printing a PivotTable may be slow, you may notice that the same behavior does not occur when you view the object in PivotTable view. This is because the PivotTable component only opens the number of ADO recordsets required to display the cells that are currently visible on the screen. As you scroll up or down the window to view other cells, the PivotTable component opens additional ADO recordsets as needed. This differs from previewing or printing because the PivotTable component must open all recordsets required by the PivotTable before the first page is previewed or printed.

The length of time it takes for the data to be displayed depends on a number of factors, such as the number of cells displayed within the PivotTable, the processing speed of your computer, and the amount of free memory on your computer.

Steps to Reproduce the Behavior

WARNING: Following these steps will cause Microsoft Access to stop responding for some time on your computer. Make sure you save and close any open work on your computer before following these steps.
  1. Repeat steps 1 through 7 of the "Reducing the Amount of Detail Data Displayed" section earlier in this article.
  2. On the File menu, click Print Preview.
Note that you receive the message that is mentioned at the beginning of this article. If you click OK at this point, Microsoft Access may appear to stop responding for a long time. However, the table will eventually be displayed in Print Preview mode.

Modification Type:MinorLast Reviewed:6/7/2004
Keywords:kbprint kberrmsg kbprb KB282315