SQL Select string
szSQL = "SELECT * FROM [" & SourceSheet$ & "$" & SourceRange$ & "] " & _
"WHERE LastName = '" & myName & "' AND KeyCode = '" & myCode
& "';"
--
---
HTH
Bob
(there's no email, no snail mail, but somewhere should be gmail in my addy)
"Geoff" wrote in message
...
Hi
I use ADO to get the first row of data from multiple unopened wbooks.
This string gets the contents of every cell in row 1 given that
SourceSheet
= "Sheet1" and SourceRange = "A1:IV1"
szSQL = "SELECT * FROM [" & SourceSheet$ & "$" & SourceRange$ & "];"
Instead of all the row how can I write a string to result in specific
names
eg Last Name, Keycode, Company etc?
T.I.A.
Geoff
|