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

how to display raw xml

1 Answer 113 Views
Grid
This is a migrated thread and some comments may be shown as answers.
TMLP
Top achievements
Rank 1
TMLP asked on 10 Jun 2010, 08:32 PM
Hi,

I have a RadGrid control with databound from SQL server. One of the columns is string datatype that contains XML. When the data is displayed, I want the raw xml to show including the XML tags. Right now, what it does is dropping xml tags. I've changed string datatype in DB column to XML datatype. It seems to be the same


How can I set my grid to do this?

ps. Currently, the colums of my grid is autogenerated.


Thanks..

1 Answer, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 11 Jun 2010, 04:46 PM
Hello Loya,

Please set HtmlEncode="true" to your column:
<telerik:GridBoundColumn
   DataField="MyXmlField"
   HtmlEncode="true"
   ...
/>

Regards,
Daniel
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
Grid
Asked by
TMLP
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Share this question
or