Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Populating an MSHFlexGrid using ADO control

Status
Not open for further replies.

Sorry

Technical User
Jun 17, 2001
8
0
0
AU
Sorry I am fairly new to VB and would really aprieciate some advice.

After having obtained the results from an SQL query in an ADODB recordset, rstScore is this a fairly efficient method of populating a Flex Grid, it seems rather cumbersome.


rstScores.Open strSQLScores, Cnxn, adOpenStatic,
adLockBatchOptimistic

Do While Not rstScores.EOF
With rstScores
fname = !fname
sname = !sname
playerid = !Id
state = !state
score = !score
msfgScores.AddItem (playerid + Chr(9) + sname +
Chr(9) + fname + Chr(9) + state + Chr(9) + score)
.MoveNext
End With
Loop


Thank you to any one that can help.
 
try this, it works great for display data on flexgrid
Set flexgrid.recordset = rs

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top