Unloading Form from Within DBGrid Event Causes GPFLast reviewed: January 26, 1996Article ID: Q142839 |
The information in this article applies to:
SYMPTOMSWhen unloading a form from within an event of a Data Bound Grid control a General Protection fault will occur in VB.EXE or an Exception fault will occur in VB32.EXE.
CAUSEThe cause of the problem is that the unload event is destroying the recordset object of the data control. When the DBGrid gets control back the recordset pointer is no longer valid.
STATUSMicrosoft has confirmed this to be a problem in Visual Basic version 4.0. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.
WORKAROUNDTo work around this problem, add a timer control to the form and allow the "Unload Me" command to happen here rather than in the DBGrid control. Here is a step-by-step example to correct the problem:
MORE INFORMATION
Steps to Reproduce
|
Additional reference words: 4.00 vb4win vb4all gp-f gpf gp
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |