Microsoft KB Archive/223248

= ACC2000: PreviousSection Property Causes Microsoft Access and Internet Explorer to Quit Unexpectedly =

Article ID: 223248

Article Last Modified on 6/29/2004

-

APPLIES TO


 * Microsoft Access 2000 Standard Edition

-



This article was previously published under Q223248



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

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



SYMPTOMS
Microsoft Access or Microsoft Internet Explorer unexpectedly quits when you browse to a data access page that tries to reference the PreviousSection property.



RESOLUTION
Avoid using programming code that references the PreviousSection property.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.



MORE INFORMATION
This problem only occurs when you try to access the PreviousSection property on a grouped or banded data access page, but only when the group contains no matching records. If the group you are viewing contains one or more matching records, the PreviousSection property can be successfully accessed.

Steps to Reproduce the Behavior
 Create a new database. Import the following two tables from the sample database Northwind.mdb:

Categories

Products

  Create a new query by using the following SQL statement, and then run the query: DELETE *, CategoryID FROM Products WHERE CategoryID=8;  Click Yes to deleted the specified records, and then close the query without saving it. Click Pages in the Database window, and then double-click Create data access page by using wizard.</li> In the Page Wizard, click Table: Products under Table/Queries, click the >> button to select all fields, and then click Finish.</li> In Design view of the new data access page, expand Tables, and then expand Categories in the field list.</li> Drag the CategoryID field and hold it directly above the bar that is labeled Header: Products. After you see a blue line with inward pointing arrows, release the mouse button. This creates a text box in a new section called Header: Categories.</li> On the View menu, click Sorting and Grouping, and for the Categories group, set Group Footer to Yes.</li> Close the Sorting and Grouping dialog box, and note the new section called Footer: Categories. Add a command button to this section.</li> Assign Test to the ID property of this button.</li> Click the bar labeled NavigationSection: Products, and then press DELETE to remove this section.</li> Start Microsoft Script Editor, and then in the Script Outline, expand Test, and double-click onclick.</li>  Enter the following script: <SCRIPT event=onclick for=Test language=vbscript> </SCRIPT> </li> Close the Script Editor and when you are prompted to save changes, click Yes, saving the page as Page1.htm .</li> Switch to Page view and note that there are categories 1 through 8. If you expand any of the first 7 categories, you see the products that match that category, and you can successfully click the button that references the PreviousSection property.

If you go to category 8, note that the Expand button for category 8 will still switch from Plus to Minus, even though there are no matching products. As long as you have category 8 collapsed, you can click the button and successfully set the MySection variable to the PreviousSection property. But if you expand category 8 and then click the button, Access appears to to stop responding (hang), and will then shut down completely.</li></ol>

Additional query words: pra crash fail shut down

Keywords: kbbug kbpending KB223248

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.