Thursday, November 11, 2010

DataGridView WordWrap

To get cell text to word wrap is easy once you know the combination of properties to set:

DataGridView > AutoSizeRowsMode = AllCells
DataGridView > Columns > *Your Column* > Default Cell Style > Wrap Mode = True
DataGridView > Columns > *Your Column* > AutoSizeMode = DisplayedCells

3 comments:

  1. Hey,

    Thanks a lot! Exactly what I needed. I've been looking for like 30minutes and working on this problem for over 2 hours.

    Again, thank you :)

    ReplyDelete
  2. Thanks! saved me a ton of time :)

    ReplyDelete