|
-
Jun 13th, 2000, 07:24 PM
#1
Thread Starter
New Member
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 ??
-
Jun 13th, 2000, 11:29 PM
#2
Lively Member
Instead of using the data controller for ADO I have been just setting the grid equal to a defined recordset.
Like this:
Set tempRcSet = ("Select * From [table]",dbConnect,....)
set grid.Datasource = temprcset
This seems to allow me to change the recordset or recordsource without an error.
Are You using the OLE Grid as well?? Because this may be causing your problem.
Hope this helps.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|