Unanswered: ADO find method takes only numbers? WTF?
Like everything ( this started as a very simple task and went terribly wrong.
Im trying to get a key value (string) from a drop down box ([ClientID]), look it up in a table (T_Clients), and get the value of the column PName from the table.
Dim cnConnect As ADODB.Connection
Dim rcdRecord As New ADODB.Recordset
Dim s As String
Set cnConnect = CurrentProject.Connection
rcdRecord.Open "T_Clients", cnConnect, adOpenKeyset, adLockOptimistic, adCmdTable
s = "[Serial] = " & [ClientID]
If Not rcdRecord.EOF Then
[PName] = rcdRecord![PName]
Now - this works fine when [ClientID] is numbers only, but doesnt work when [ClientID] has letters in it.... I get the error: "3001: Arguments are of the wrong type, out of acceptable range etc...etc...".
Needles to say - [Serial] is STRING.
Anyone has an idea what did I do wrong?