I know I can set WrapMode
to true on the DefaultCellStyle
of the RowTemplate
, however this doesn\'t give me the behaviour I want. I am dis
if ((!e.Value.Equals("OK")) && e.ColumnIndex == 6)
{
e.CellStyle.WrapMode = DataGridViewTriState.True;
//dgvObjetivos.Columns[2].AutoSizeMode = DataGridViewAutoSizeColumnMode.DisplayedCells;
dgvObjetivos.AutoSizeRowsMode = DataGridViewAutoSizeRowsMode.AllCells;
}
http://kshitijsharma.net/2010/08/23/showing-multiline-string-in-a-datagridview-cell/