Microsoft KB Archive/900096

= A grid on a parent form may be blank in a Visual FoxPro 9.0-based application =

Article ID: 900096

Article Last Modified on 2/4/2006

-

APPLIES TO


 * Microsoft Visual FoxPro 9.0 Professional Edition

-





SYMPTOMS
In a Microsoft Visual FoxPro 9.0-based application, a grid on a parent form may be blank. This problem occurs when the following conditions are true:
 * You upgrade the application to Visual FoxPro 9.0.
 * The application has a parent form that has page frames, and the page frames contain a grid.
 * You either close the child form or resize the form.



CAUSE
This problem may occur when the grid columns have functions or when you run the ControlSource method on the child form, and the child form does not redraw the grid correctly.



WORKAROUND
To work around this problem, follow these steps:   Redraw the grid after the child form is closed to add a GridRefresh method to the grid class. To do this, use code that is similar to the following. local lnSaveLockScreen lnSaveLockScreen = ThisForm.LockScreen ThisForm.LockScreen = .t.   This.Refresh ThisForm.LockScreen = lnSaveLockScreen   Bind both the form activate event and the form resize event to the grid.Init method by using code that is similar to the following. BindEvent(thisform, &quot;activate&quot;, ;   this, &quot;gridrefresh&quot;,1)

BindEvent(thisform, &quot;resize&quot;, ;   this, &quot;gridrefresh&quot;,1) 



STATUS
Microsoft has confirmed that this is a bug in the Microsoft products that are listed in the &quot;Applies to&quot; section.

Keywords: kbtshoot kbbug KB900096

-

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

© Microsoft Corporation. All rights reserved.