I have a GridView with several fields, one of which can potentially have a crazy wide value in it like this:
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
If that sort of thing is in the field, I want it to wrap.
I can easily insert a character in code every 50 characters or so...but what character? If I use \r\n or a space or the like, then sometimes the setting doesn't wrap (because a different row's 50 chars is wider), and I get something like this:
mmmmmmmmmm
mmmmm
llllllllll llllllllll llll
I don't want those spaces to show up; I just want the line to wrap there if it can, but otherwise to show nothing:
mmmmmmmmmm
mmmmm
llllllllllllllllllllllll
Also, I'd rather leave HtmlEncode on if possible. Is there a way to do this?