Setting width of a column in a DataGrid

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi l&g

It's weird but I can't find an easy way to set the width of a column in a DataGrid. It must be hidden somewhere. I searched google but it's all vb-ish and not to the point. Can someone sketch me how I should do this

What I actually want to do is to specify the width of a column relative to the width of the DataGrid control so that the columns always span the entire width of the DataGrid. For instance 4 columns, 10%, 20%, 30% and 40%

Thanks
 
TT said:
Hi l&g,

It's weird but I can't find an easy way to set the width of a column in a DataGrid. It must be hidden somewhere. I searched google but it's all vb-ish and not to the point. Can someone sketch me how I should do this?

What I actually want to do is to specify the width of a column relative to the width of the DataGrid control so that the columns always span the entire width of the DataGrid. For instance 4 columns, 10%, 20%, 30% and 40%.

Thanks,

Hi Tom,

http://www.syncfusion.com/FAQ/WinForms/FAQ_c44c.asp#q792q

Cheers

Arne Janning
 
And if you want percentages then:

width = Unit.Percentage(10);


a DataGrid. It must be hidden somewhere. I searched google but it's all
vb-ish and not to the point. Can someone sketch me how I should do this?to the width of the DataGrid control so that the columns always span the
entire width of the DataGrid. For instance 4 columns, 10%, 20%, 30% and 40%.
 
Back
Top