Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help importing Paradox table into Access with VBA

Status
Not open for further replies.

Dan8376

Technical User
Jan 29, 2002
25
US
Hi,

I'm trying to import a Paradox file into my database, but I'm getting the following error:

Run-time error '3044':
'O:\DATA\ACCESS\TG070723.DB' is not a valid path. Make sure that the path name is spelled correctly and that you are connected to the server on which the file resides.

Here is the code:
strLoc = "O:\DATA\ACCESS\"
strDatabase = [Forms]![frmImportDataInput]![txtDatabaseName]
DoCmd.TransferDatabase acImport, "Paradox 7.x", strLoc & strDatabase

I've checked the path, I know it is spelled correctly. I have access to the drive where the database is located. I can manually import the file by using the Get External Data command. Anyone have any suggestions on what my problem is?

Thanks
Dan
 
It has been a while since I have done it but according to the docs you need....

TransferDatabase(TransferType, DatabaseType, DatabaseName, ObjectType, Source, Destination, StructureOnly, StoreLogin)

at the least you should have

'includet the file name
strLoc = "O:\DATA\ACCESS\TG070723.DB"
DoCmd.TransferDatabase acImport, "Paradox 7.x", strLoc, "tablenamehere"

Uncle Mike

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top