vb and excel as datasource
a. I did not think that you had to use the first sheet: you can use any sheet
b. You cannot UPDATE an excel ODBC data source; I tend to create a record set object and open it without reference to a connection object
c. I thought, incorrectly, there might be some issue with the name of the sheet
I tried
Cnn="Provider=MSDASQL;Driver={Microsoft Excel Driver (*.xls)};DBQ=" & App.Path & "\caretaker.xls
Sql= "SELECT * FROM [29-Dec-2003$a2:G500]
Set ADORS=CreateObject("ADODB.Recordset"
ADORS.Open Sql,Cn
It works for me
|