I need help to delete all the records from a FOXPRO table using VB. I typed the following code:
'CONNECT
Set wrkSpace = CreateWorkspace("", "admin", "", dbUseODBC)
Set db = wrkSpace.OpenDatabase("Visual FoxPro Database"
Set rs1 = db.OpenRecordset("TAN2001"
'DELETE ALL RECORDS FROM ACCESS TABLE BEFORE POPULATING
db.Execute "DELETE ALL FROM TAN2001"
db.Execute "PACK TAN2001"
At this point I receive an error "ODBC call failed"
My question is: how can you delete records from a .DBC
a quick example would be very helpful!
'CONNECT
Set wrkSpace = CreateWorkspace("", "admin", "", dbUseODBC)
Set db = wrkSpace.OpenDatabase("Visual FoxPro Database"
Set rs1 = db.OpenRecordset("TAN2001"
'DELETE ALL RECORDS FROM ACCESS TABLE BEFORE POPULATING
db.Execute "DELETE ALL FROM TAN2001"
db.Execute "PACK TAN2001"
At this point I receive an error "ODBC call failed"
My question is: how can you delete records from a .DBC
a quick example would be very helpful!