Using the VFP FoxPro ODBC Driver with Your Visual Basic Application
Your Microsoft® Visual Basic® application can communicate with Visual FoxPro data by creating a data control that connects to a Visual FoxPro data source.
To connect to Visual FoxPro data using the Data Control in Visual Basic
Create a data source named "test" that connects to the TasTrade sample database included in Visual FoxPro. The default Visual FoxPro installation places the TasTrade sample database in the location:
In Visual Basic, create a new form and place a text box and a Data control on it.
Change the Data control's Connect property as follows:
Change the RecordsetType property to the following:
2 - Snapshot
Change the RecordSource property to the following:
Change the DataSource property for the text box to the default name for the Data control to the following:
Change the text box's DataField property to the following:
Run the form, and use the Data control to skip through the customer id fields from the Visual FoxPro TasTrade sample database.