Category / Section
How to append a long text with trimming(...) character in a WinForms GridGroupingControl?
1 min read
Trimming text
In GridGroupingControl, when you display the long text in a cell, the exceeding text is hidden in that cell. To display a long text with trimming (...) character in GridGroupingControl, it can be achieved by setting the Trimming property as EllipsisCharacter.
C#
//Set ellipsis character for specific column in a grid. this.gridGroupingControl1.TableDescriptor.Columns["Ship"].Appearance.AnyRecordFieldCell.Trimming = StringTrimming.EllipsisCharacter;
VB
‘Set ellipsis character for specific column in a grid. Me.gridGroupingControl1.TableDescriptor.Columns("Ship").Appearance.AnyRecordFieldCell.Trimming = StringTrimming.EllipsisCharacter
Screenshot
Figure 1: Trimming
In the above image, ship column text has been trimmed.
Note:
Before setting the Trimming property, you have to confirm that WrapText is set as False.