MS(H)FlexGrid row count limitation?

HorstTappert
01-14-2005, 07:27 AM
hi there,

does anyone know how many rows a flexgrid can handle? i have a recordset with about 5000 records and there are only 370 added to the grid....

fast help needed!

thanks a lot.

btw: i didnt find any information on this on the net! is that possible??


here is the code:
----------------------------------------------------
i% = 0
Do Until rs.EOF
i% = i% + 1
rs.MoveNext
Loop
Debug.Print "Records in RS: " & i%

Set grdNamespaces.DataSource = rs
DoEvents

Debug.Print "Records in Grid: " & grdNamespaces.Rows
------------------------------------------------------
results:
Records in RS: 5071
records in grid: 370

thanks for the help!

matthias

Shurik12
01-14-2005, 07:49 AM
Hi,

Are you reffering to these issues?

http://support.microsoft.com/kb/194653/en-us
http://support.microsoft.com/?scid=kb;en-us;253211

HorstTappert
01-14-2005, 07:58 AM
well, this looks good. but my grid is only displaying the first 370 records, not 2048. anyway one way to go!

thanks

Shurik12
01-14-2005, 08:09 AM
How are you opening you recordset and connection, could you sho the code?

HorstTappert
01-14-2005, 08:13 AM
sure, here it is:

#connection
Public gdbhost As New ADODB.Connection
Public grs As New ADODB.Recordset

gdbhost.Open "DSN=" & sDSN, sUsername, sUserPWD
rs.Open ssql, , adOpenUnspecified

and then
Set grdNamespaces.DataSource = rs


does that help?

Shurik12
01-14-2005, 08:16 AM
Try to add

rs.CursorLocation=adUseClient before opening the recordset

HorstTappert
01-14-2005, 08:24 AM
worked! thanks a lot! did you have the same prob before or where did you get this tweak?

Shurik12
01-14-2005, 08:28 AM
good.
been there, seen that....

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum