Hi,
I am using this code to import a .csv file selected by user ( the textbox Cmbhavfile holds the path for this file) to a table in Access but get an error:
[Microsoft] [ODBC Text Driver] Syntax error in From Clause
I don't understand what is wrong because the same code is running well on a...
Hi,
Thanks William and CClint for your insights!
I am now able to import a csv file to a table in Access. But the code that William has provided above, only allows the csv file specified by strCSV to be imported to a new table in the Access database.
However I need it to work a little...
Hi,
Thank you for responding william.
I am new to VB and am not familiar with what you are talking about. I want to Import the CSV file to a table in Access. So I tried openning a connection to the database and using TransferText.
What should I do to resolve this?
Thanks,
D
Hi,
I am trying to import a CSV file using TransferText in VB. I am getting this error:
Run Time Error:
Object Required
when I try to execute this code:
Private Sub Next_Click()
Dim cnn As New ADODB.Connection
'Open the Connection
cnn.Open ("Provider=Microsoft.Jet.OLEDB.4.0;Data...
Hi,
I am trying to import a dbase IV file into table in Access using the TransferDatabase command.
I get this error:
Run-time error: 91
Object Variable or With Block Variable not set.
when I run this code:
Private Sub Next_Click()
Dim cnn As ADODB.Connection
cnn.Open _...
AHA!
So I don't get the "Object Required" error anymore. So you have star for that (I was so tired of seeing the same error... :) thanks!)
But now we a different one.
I get this error:
Run-time error: 91
Object Variable or With Block Variable not set.
when I run this code...
Thanks!
I shrunk the .dbf file name to less than 8 characters and it worked. I am just wondering, why does i have to be a max of 8 chars to be imported while excel doesn't?
anyway, thanks a lot.
D
Thanks for the reply Patrick.
Here is what I am trying to do. The path of the dBase IV file which is to be imported is in a textbox named 'Cmbhavfile'. I am using the following code to import te file into a table in the Access Database:
Private Sub Next_Click()
Dim cnn As New ADODB.Connection...
Hi,
I am having trouble importing a dBase IV file into Access through VB.
The path of the dBase file which is to be tranferred is in a text box. I am trying to use the TransferDatabase Command but I get the following error:
Object required
What should I do to resolve this?
Thank you,
Dheeraj
Hi,
Yes, the Import - Files of Type pick list includes dBase IV as a file type. I keep getting the same error, no matter what I try. I have Access 2000 with Windows XP. I hope that is not the problem.
Thanks,
D
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.