How to resize a Data Grid View Column size
i want to resize c# data grid view column 开发者_如何学运维to a custom size. how i can do this?
Set the DataGridViewColumn.Width Property.
You can do this either in the Visual Studio Designer or through code:
DataGridViewColumn column = dataGridView.Columns[0];
column.Width = 60;
You should be aware that the DataGridViewColumn.AutoSizeMode Property setting can affect a column's width too.
精彩评论