Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6867571
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T03:19:34+00:00 2026-05-27T03:19:34+00:00

I have a telerik:GridBoundColumn in my telerik:RadGrid as a string type with some XML

  • 0

I have a telerik:GridBoundColumn in my telerik:RadGrid as a string type with some XML codes.

How can I show that column (raw XML) in that RadGrid without rendering?

My problems:
my grid direction is right to left for some reason…
so at first I should change the xml direction like below :

<telerik:GridBoundColumn DataField="Settings" FilterControlAltText="Filter Settings column" DataFormatString="<span style='direction:ltr;'>{0}</span>"
    HeaderText="Settings" SortExpression="Settings" 
    UniqueName="Settings" FilterImageToolTip="Filter" HtmlEncode="false">
    <HeaderStyle HorizontalAlign="Right" VerticalAlign="Middle" />
    <ItemStyle HorizontalAlign="Left" VerticalAlign="Middle" />
</telerik:GridBoundColumn>

Currently we have an XML string with ltr direction in grid. After that I change to HtmlEncode="TRUE", but by doing so I lose the ltr direction.
so I set HtmlEncode back to false.

I figured out I can use <xmp> or <pre> elements. But with <xmp> I have some replacement of < and > in grid and also it has been deprecated… and with <pre> I should change all < to &lt; and > to &gt; in my database, which is unfeasible.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T03:19:35+00:00Added an answer on May 27, 2026 at 3:19 am

    Add handler for onItemDataBound for your Grid

    <telerik:RadGrid ID="RadGrid1" runat="server" AllowFilteringByColumn="True"
                AllowSorting="True" PageSize="50" ShowFooter="True" AllowPaging="True" 
                AutoGenerateColumns="False" GridLines="None" ShowStatusBar="true" 
                    onitemdatabound="RadGrid1_ItemDataBound">
    

    And codebehind:

     protected void RadGrid1_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
     {
                if (e.Item is GridDataItem)
                {
                    GridDataItem item = e.Item as GridDataItem;
                    item["XmlColumn1"].Text = Server.HtmlEncode(item["XmlColumn1"].Text);
                    item["XmlColumn2"].Text = Server.HtmlEncode(item["XmlColumn2"].Text);
                }
    
      }
    

    Should do the trick.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Telerik RadGrid with a GridTemplateColumn that contains a checkbox, as follows:
I have some boiler-plate script required for a Telerik RadGrid on one of my
I have a Telerik's RadGrid which has 2 columns like this: <Columns> <telerik:GridBoundColumn HeaderText=AirlineCode
I have a Telerik RadGrid on my aspx web page. I notice that when
I have a telerik radgrid that is doing an insert using an objectdatasource. The
I have a Telerik RadGrid that is bound to a Linq Datasource. On the
I have a telerik radgrid that has an allows inserts. After clicking the Add
I have a telerik:RadGrid that is bound to a SQL Data Source. One of
I have a Telerik RadGrid. The initial DataSource that is bound to the grid
I have a Telerik RadGrid and have a very simple Hierarchical dataset that I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.