Article ID: 140770
Article Last Modified on 11/18/2003
APPLIES TO
- Microsoft Visual Basic 4.0 Standard Edition
- Microsoft Visual Basic 4.0 Professional Edition
- Microsoft Visual Basic 4.0 32-Bit Enterprise Edition
This article was previously published under Q140770
SYMPTOMS
When you attempt to open a Microsoft FoxPro for Windows database file by
connecting the database file to a Data Control in a Visual Basic version
4.0 program, the DatabaseName dialog box selects only files with the .dbf
file name extension. Moreover, if you select a file with the .dbc file name
extension, the DatabaseName property of the Data control displays the path
without the file name.
CAUSE
This behavior occurs because the Data control in Visual Basic assumes that
a .dbc file is an unlinked FoxPro 3.0 table.
The 16-bit edition of Visual Basic version 4.0 cannot read files in the
Visual FoxPro version 3.0 format.
RESOLUTION
Use the following steps to work around this problem:
- Set the Connect property of the Data1 Data control to FoxPro DBC.
- Add the FoxPro 3.0 database file name to the path in DatabaseName
property of the Data control. This file must have the .dbc file name
extension.
- Select a table in the RecordSource property of the Data control. You can
now use bound controls on this recordset.
STATUS
Microsoft has confirmed this to be a problem in Visual Basic version
4.0 for Windows. We are researching this problem and will post new
information here in the Microsoft Knowledge Base as it becomes available.
Additional query words: update readonly
Keywords: kbprb KB140770