7 Answers, 1 is accepted
0
Hi Temp,
You can put it in the ItemDataBound event handler. The ItemDataBound event is raised when a data item is bound to data in the RadGrid control. This allows you to provide an event-handling method that performs a custom routine, such as modifying the values of the data bound to the item, whenever this event occurs.
I have prepared especially for you a sample application which represents how to modify the text in appropriate columns
Please review the code in the project for further details, and let me know if you need further assistance.
Greetings,
Plamen
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
You can put it in the ItemDataBound event handler. The ItemDataBound event is raised when a data item is bound to data in the RadGrid control. This allows you to provide an event-handling method that performs a custom routine, such as modifying the values of the data bound to the item, whenever this event occurs.
I have prepared especially for you a sample application which represents how to modify the text in appropriate columns
Please review the code in the project for further details, and let me know if you need further assistance.
Greetings,
Plamen
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
0

Temp
Top achievements
Rank 1
answered on 11 Jul 2008, 12:05 AM
Thanks for your help.
0

Jason Lee
Top achievements
Rank 1
answered on 11 Sep 2008, 11:25 AM
Dear Sir,
Is there a better way to make it?
I want to encode html markup in grid column, too. However, I have already used RadGrid in lots of pages. Moreover, it seems to write codes in ItemDataBound event handler for each column......
Suggestion:
Is possible radGrid to provide a property, such as "EncodeHTMLMarkupInColumn"...
If the property is true, all the content will be encoded?
Thank you
Is there a better way to make it?
I want to encode html markup in grid column, too. However, I have already used RadGrid in lots of pages. Moreover, it seems to write codes in ItemDataBound event handler for each column......
Suggestion:
Is possible radGrid to provide a property, such as "EncodeHTMLMarkupInColumn"...
If the property is true, all the content will be encoded?
Thank you
0

Jason Lee
Top achievements
Rank 1
answered on 12 Sep 2008, 04:39 AM
Dear Sir,
It seems GridView server control support what I said
It seems GridView server control support what I said
<asp:GridView ID="grvResult" runat="server" AutoGenerateColumns="False" Width="100%">
<Columns>
<asp:BoundField HeaderText="OperationDate" DataField="OperationDate" HtmlEncode="True">
</asp:BoundField>
<asp:BoundField HeaderText="TotalRate" DataField="TotalRate" HtmlEncode="True">
</asp:BoundField>
</Columns>
</asp:GridView>
0
Hello Jason,
HtmlEncode property to GridBoundColumn will be added for the Q3 2008 release, expected at the beginning of November. I hope this is good news for you.
Kind regards,
Nikolay
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
HtmlEncode property to GridBoundColumn will be added for the Q3 2008 release, expected at the beginning of November. I hope this is good news for you.
Kind regards,
Nikolay
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0

Phillip
Top achievements
Rank 1
answered on 14 Feb 2009, 03:38 AM
HI Jason,
I am having the same problem for the RadComboBox, where all the HTML is displaying encoded. For example '&' is displaying as '&'.
Any ideas?
Thanks
Phil
I am having the same problem for the RadComboBox, where all the HTML is displaying encoded. For example '&' is displaying as '&'.
Any ideas?
Thanks
Phil
0
Hello Phillip,
You can use HtmlDecode method in such cases.
Greetings,
Veselin Vasilev
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
You can use HtmlDecode method in such cases.
Greetings,
Veselin Vasilev
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.