PDA

Click to See Complete Forum and Search --> : populate a DBGrid using a rcordset


shovels
Mar 21st, 2000, 09:16 PM
Hi,
Can anyone please tell me how to populate a DBgrid using a recordset. I have created my recordset set using the following code:

Set rs = New adodb.Recordset
rs.Open lpzSQL, conn, adOpenKeyset, adLockOptimistic

and I know that it succeeds in getting the info from the DB.
Any suggestions would be greatly appreciated.
Cheers!

voynovam
Mar 21st, 2000, 09:29 PM
You must set DataSource property of your grid:

DBGrid1.DataSource=rs