Hi
There is requirement for settting the row height of ultragrid to three times the default height. Also if the text doesn't fit into the available width and height, then it should show the ellipsis at end and show full text in the tooltip on grid cell
As far I know that I can either set the row to autosize according to the length of text or can set the elipsis to show grid cell. But I don't know how can I set the both at one time
Thanks
Narinder
and do the autoresize on the row, too.
After adding my muliline data I just needed to ...
selectedCell.Row.Cells("myHappyField").Column.PerformAutoResize()
If I set it on InitializeLayout then all of the rows would be set, wouldn't they?
In my grid initialization I have:
(I go through the bands because I have Custom grid settings loading on Form Load)
''*********************************************************************************
''FIELDS WITH SPECIAL FORMATTING NEEDS
For xr = (.Bands.Count - 1) To 0 Step -1
For m As Integer = 0 To .Bands(xr).Columns.Count - 1
Select Case .Bands(xr).Columns(m).Key
Case "myHappyField"
.Bands(xr).Columns("myHappyField").CellMultiLine = DefaultableBoolean.True
.Bands(xr).Columns("myHappyField").VertScrollBar = True
End Select
Next
'then I am setting the grid to Auto free
.Override.RowSizing = UltraWinGrid.RowSizing.AutoFree
Just need the 'magical jelly bean' to make it automatically expand those rows with the multilines filled.
Hi,
Setting this in InitializeRow is a bit odd, since that event fires for each row. InitializeLayout would make more sense. :)
Ka ching!!!
Just exactly what i needed:
ultraGrid1.DisplayLayout.Override.RowSizingAutoMaxLines = 3;
Using it in the Initialize Row event with the grid set to auto free and a quick test of the count of "vbcrlf"s in my multiline column and you get ...
Dynamic Row Heights
Thanks,