We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Resize row height

I have a databoundgrid with resizetofit = false because of having a column which is extended to the greatest width to fill out the client area of the grid. Now I need some cells in a column to be as large as the text which is in it (AllowSize and WrapText = true). eg. in a cell is a value of texttype -> resize in a cell is a value of datetype -> don't resize Have any idea how to do that? Peter

1 Reply

Administrator April 4, 2003 04:00 PM UTC

After one of your datecolumns changes (maybe catch it in CurrentCellConfirmChanges), try explicitly calling grid.Model.ColWidths.ResizeToFit passing in a range containing your cell. The autosize style property only works as text is being typed into a TextBox cell. It does not work for a MonthCalendar cell.
Loader.
Live Chat Icon For mobile
Up arrow icon