This is a migrated thread and some comments may be shown as answers.

Turning off text wrapping on a grid column

3 Answers 144 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Philip
Top achievements
Rank 1
Philip asked on 25 May 2010, 10:37 AM
Hi,

I am currently binding a radgrid to an object in which one of the properties can have a large amount of free text, which causes the text to wrap and the row height to expand to accomodate it. I really want to have the text go to ellipses (e.g. 'mary had a little...') when it runs out of room, but I cannot seem to get it to work. How can I do this for one or more columns?

3 Answers, 1 is accepted

Sort by
0
Stefan Dobrev
Telerik team
answered on 25 May 2010, 11:30 AM
Hello Philip Barton,

You can use the TextTrimming property of the column.

Greetings,
Stefan Dobrev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Philip
Top achievements
Rank 1
answered on 25 May 2010, 11:47 AM
Thanks for the quick response Stefan.
I did try that, but it doesn't seem to work. I am using:

 

 

 

radGridFindResults.Columns["Comment"].TextTrimming = TextTrimming.WordEllipsis; 

I've got this in the DataLoaded event - should I be doing this someplace else perhaps?

0
Stefan Dobrev
Telerik team
answered on 26 May 2010, 03:35 PM
Hello Philip Barton,

I have just tried this and it is working fine on my end. Please find attached a sample project which illustrates this.

Regards,
Stefan Dobrev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
GridView
Asked by
Philip
Top achievements
Rank 1
Answers by
Stefan Dobrev
Telerik team
Philip
Top achievements
Rank 1
Share this question
or