hello, I'm trying to put vbcrlf in a cell and then autoresize that row so that the cell can display a few data items. I.e. I have the column bound to a string and the contents of the string is:
"7/1/2008" & vbCrLf & "7/2/2008" & vbCrLf & "7/3/2008"
I want it to show up in the cell as (but w/o the bulleted list look):
Thanks
Rocky
As a followup to this question... if I use the following code after binding the grid:
This will make it so my cell displays the first date (stops displaying at the first vbCrLf it encounters, but if I mouseover the field, the caption that appears DOES correctly display the 3 dates, even though the 2nd and 3rd don't show up in the field. The 3 dates are also shown in the caption on separate lines, as I need.
Any ideas?
Hi Rocky,
Setting CellDisplayStyle is not what you want. That setting allows you to do formatting in the cell like colors and such, it has nothing to do with the kind of mulitline you are looking at here.
You probably just need to set CellMultiline to true on the column. You may also want to check out RowSizing, AllowColSizing, and the PerformAutoResize method on the row and the column.