Using DAO it is possible to search/update the contents of a DBGrid by linking the recordsource of a data control object to an unbound text box such as,

txtsearch on Change()

data1.RecordSource = "SELECT * FROM Customer WHERE Surname like " & """" & txtsearch.text & "*"""

bla bla etc etc

the DBGrid is of course is bound to Data1.

How is this method possible in ADO ?? I have tried different ways but get a message saying I can't change the source whilst the connection is open.

Can anybody help me ??