Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Connection to MS Access
Message
From
03/11/2005 10:40:07
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01064680
Message ID:
01064973
Views:
13
>Hi,
>
>Unfortunately, my head would be placed on a platter if I sent this file to you, as much as I would like to.
>
>But, thanks again.
>Vince

Also you can try this:
LOCAL oADConn, oADComm, oADRSet
oADConn = CREATEOBJECT("ADODB.Connection")

*** Change full_path_to_your_MDB to your DB (I forgot what variables you used there :o)
oADConn.ConnectionString= [Provider=Microsoft.Jet.OLEDB.4.0;Data Source=]+ full_path_to_your_MDB+[;]
oADConn.Open()

oADComm = CREATEOBJECT("ADODB.Command")
oADComm.ActiveConnection = oADConn

*** Hardcode Your_table_name_here here, this code is just for testing
oADComm.CommandText= "SELECT * FROM [" + Your_table_name_here + "]"

oADRSet = oADComm.Execute()
oADRSet.MoveFirst()
DO WHILE NOT oADRSet.EOF
  ?
  FOR EACH oField IN oADRSet.Fields
      ?? oField.Value
      ?? SPACE(5)
  NEXT
  oADRSet.MoveNext
ENDDO
See if this connection can be made w/o any errors.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform