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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Not all of my records - MSHFlexgrid

Status
Not open for further replies.

JonJacobik

Technical User
Dec 9, 2001
27
0
0
US
I have flexgrid problem. Code seems to work perfectly, but the flexgrid only loads about 2000 of 11000 records.

Is there a property limitting the number of records in a the recordset? Here's the code that makes it all happen:

sConnect = "Provider=Microsoft.Jet.OLEDB.4.0;Persist Security Info=False;User ID=Admin;Data Source=RESULTS2K.MDB;Mode=Share Deny None;Extended Properties=';COUNTRY=0;CP=1252;LANGID=0x0409';Locale Identifier=1033;Jet OLEDB:System database='';Jet OLEDB:Registry Path='';Jet OLEDB:Database Password='';Jet OLEDB:Global Partial Bulk Ops=2"
sSQL = "select ReFerence,Title,Artist,Category,Tempo,Length,Ending,Intro,Year from Music Order by Title"

' open connection
Set dfwConn = New ADODB.Connection
dfwConn.Open sConnect
' create a recordset using the provided collection
Set datPrimaryRS = New ADODB.Recordset
datPrimaryRS.CursorLocation = adUseClient
datPrimaryRS.Open sSQL, dfwConn, adOpenForwardOnly, adLockReadOnly
drawit
 
I am using MSHflexgrid - but here's the unusual I discovered today. My development machine will only load about 2000 lines, but running on a Win 98, same code loads 9000 lines without blinking.

The XP machine simply stops after 2000 records. - in code or compiled.

Jon
 
Are you saying the recordset only contains 2000 records when there should be many more, of the flex grid?

Change your cursor type to adOpenStatic and then see what
Debug.Print datPrimaryRS.Recordset.Recordcount
returns
 
I found the problem. An older version of MSHFLXGD.OCX was found on my development system - dated 6/24/98, when I renamed it, it forced the sytem to use a newer version dated 5/22/00. Now it works just fine.

Was their a VB update I missed?

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top