Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Best Way to Access VFP DB from Excel -- Auto. Srv or ODB
Message
 
À
10/09/1998 23:39:25
Jim Underwood
Apollo Information Systems, Inc.
Houston, Texas, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00135361
Message ID:
00136594
Vues:
29
Jim
The most memory efficient method for accessing data from a VFP database into Excel would be to use ADO.

Here's sample code:

Set oConn = CreateObject("ADODB.Connection")

'MYDSN is an ODBC system data source
oConn.Open "MYDSN","",""

Set oRecs = CreateObject("ADODB.Recordset")
oRecs.Open "Select * from customer", oConn, 3,3
Do while not oRecs.Eof

'do something with the records

' skip
oRecs.movenext

Loop


Hope this helps.

Rod
Rod Paddock
Editor in Chief CoDe Magazine
President Dash Point Software, Inc.
VP Red Matrix Technologies,Inc.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform