views:

366

answers:

4

Or is there any better suited 3rd party control for this purpose?

+8  A: 

I know that DevExpress XtraGrid supports, in theory, Int32.MaxValue rows or columns in the grid. In this case, the limit is the system memory not the grid.

But do you really need to display so much data?

Francis B.
+1 for third party option and raising question as why
curtisk
+1  A: 

Short answer: Dont do it!

Long answer: Change the FillWeight to 10 or less (default is 100). The limit you are reaching is due to the total FillWeight exceeding 64K x 100 (who knows why that is a limit).

leppie
Well, if you keep the default FillWeight, then the column limit is about 655, because ColumnCount x FillWeight < 65535! So, even if you change the FillWeight to minimum, which is 1, the maximum number of columns will be 65,535.
nullDev
Ahh, I seemed to forgot! Thanks
leppie
+2  A: 

Use a virtual list (loads only the rows that are visible). I'm not sure that WinForms ListView has a virtual mode but the WPF one does.

So create a WPF user control and set it up for VirtualMode = True and host that user control on your WinForms client with an ElementHost container.

Sorry I can't be more specific, I don't have the code to hand.

Ryan

Ryan ONeill
A: 

Xceed's DataGrid for WPF can do this easily and uses both column and UI virtualization. Check out their live demo. You can populate the demo with as many columns and rows needed to test perf. http://xceed.com/Grid_WPF_Demo.html