Microsoft KB Archive/136281

= FIX: GridBuilder Gives Data Type Error After Fields Rearranged =

Article ID: 136281

Article Last Modified on 9/30/2003

-

APPLIES TO


 * Microsoft Visual FoxPro 3.0 Standard Edition
 * Microsoft Visual FoxPro 3.0b Standard Edition

-



This article was previously published under Q136281



SYMPTOMS
The "Data Type Mismatch" error message appears when the form starts.



CAUSE
The Grid Builder leaves the original control as the column's CurrentControl property even though the CurrentControl has changed.



WORKAROUND
Enter the correct CurrentControl manually or through the Grid Builder. Then delete the incorrect control along with the text box from the column.



STATUS
Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem has been fixed in Visual FoxPro 5.0 for Windows.

In Visual FoxPro 5.0, if the order of the fields is changed in step 1, then the choices for Control Type in step 3 are set back to the default of a text box.



Steps to Reproduce Problem

 * 1) Create a form called MyGrid.
 * 2) Add a data environment to the form giving Tastrade!Products as the table.
 * 3) Drag the table from the data environment to the form to create the grid.
 * 4) Using the right mouse button, click the grid, and select Builder.
 * 5) Add Unit_Price and Discontinued to the grid.
 * 6) Click Tab 3, and change the Unit_Price's ControlType property to a spinner and the Discontinued property to a check box. Click OK.
 * 7) Using the right mouse button, click the grid and select Builder.
 * 8) On Page 1 of the Builder, change the positions of the columns in the grid using mover box controls. Click OK.
 * 9) Run the form, and verify that the "Data Type Mismatch" error occurs but the form will run.

Keywords: kbbug kbfix kbvfp500fix KB136281

-

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

© Microsoft Corporation. All rights reserved.