Hi everyone. I have a datagrid working just fine. I added a tablestyle to it and now I want to make my textboxcolumns to use wordwrap. I added the next lines to my columns
mytablestyle.gridcolumnstyles(i).wordwrap=True
but Its not working at all! Ive read some articles and seen some codes extending the datagridtextboxcolumn but non seem to work. Anyone got a working code How can I make it work

DatagridTextBoxColumn WORDWRAP
xpach
bagira20572
Speech Pathologist
Hi Ken... I thanks for the code, it works really great. Just one question, is which part is the rowheight defined This because sometimes all text in columns its smaller then the column width but it still adds some pixels to the height. Where can I changed this
Thanks
JP
CodePrince
callmekv
In addition to setting the column's WordWrap, you need to set the column's AutoSizeMode and the DataGridView's AutoSizeRowsMode property.
Jim Wooley
http://devauthority.com/blogs/jwooley/default.aspx
Aravind Biran
In my first version of this column style I made each row the right height to display the whole string. The problem with that version was everytime the column was sorted or a new row was added to the datagrid the rows would default back to its prefferedrowheight. To overcome this problem I set the preferredrowheight to largest rowheight need. The code then went ahead and set the new preferredrowheight and manually adjusted all the rows to that size.