Hello I was wondering if you could help me out with doing multiple select statements.
I have this
The line that is in bold is the one I am having trouble with. THen I want it to put the value it finds from the second select statement, into another box. Do you have any suggestions on how to do this?
I have this
Code:
objCommand.CommandText = "Select * from table"
[B]objCommand.CommandText1 = "Select * from table where number like" & Val(txtSearchList.Text)[/B]
objCommand.CommandTimeout = 30
objCommand.CommandType = adCmdText
Set objRS = objCommand.Execute
Set objCommand = Nothing
Do Until objRS.EOF
Reference(Number) = objRS("Number")
Number = Number + 1
objRS.MoveNext
Loop
objRS.Close
Set objCommand = Nothing
Set objRS = Nothing
Number = Number - 1
For display = 0 To Number
lstVoucherAmt.AddItem Reference(display)
Next
Comment