Anyone have been tried to bind data to Windows.Forms.DataGridView more than 655 Columns ?
When you tried, you can see Exception “Sum of the columns’ FillWeight values cannot exceed 65535.” ?
Solution is for this reduces the DataGridViewColumn.FillWeight. Default value is 100 and the maximum sum of FillWeight values for all columns in a DataGridView control is 65535.

What is the FillWeight in DataGridViewColumn ?
It is simply value that represents the width of the column when it is in fill mode relative to the widths of other fill-mode columns in the control.

This is the C# sample.

Share

Leave a Reply

Copyright © 2009 DevSmart(BlogReader r). Running on Wordpress | Theme by itx.