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 9211127
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T01:13:31+00:00 2026-06-18T01:13:31+00:00

<ItemTemplate> <asp:Label ID=lblCompanyName runat=server ToolTip='<%# CheckDbNull.ToStr(Eval(Name)) %>’ Text='<%# CheckDbNull.ToStr(Eval(Name)) %>’> </asp:Label> </ItemTemplate> I have

  • 0
<ItemTemplate>
   <asp:Label ID="lblCompanyName" runat="server" 
      ToolTip='<%# CheckDbNull.ToStr(Eval("Name")) %>' 
      Text='<%# CheckDbNull.ToStr(Eval("Name")) %>'>
   </asp:Label>
</ItemTemplate>

I have some data in HTML formatted like <abc>, <Name>, etc., but it will render as HTML and it is not displayed.

How do I display HTML text in grid columns? I am using Telerik:RadGrid and template column.

  • 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-06-18T01:13:32+00:00Added an answer on June 18, 2026 at 1:13 am

    use Server.HTMLEncode for displaying < and > sign.

    Follows

       Text='  <%# Server.HTMLEncode(CheckDbNull.ToStr(Eval("Name"))) %>'
    

    It changes as following

    • The less-than character (<) is converted to &lt ;.
    • The greater-than character (>) is converted to &gt ;.
    • The ampersand character (&) is converted to &amp ;.
    • The double-quote character (“) is converted to &quot ;.
    • Any ASCII code character whose code is greater-than or equal to 0x80 is converted to &#< number>, where number is the ASCII character value.
      MSDN says Server.HTMLEncode

    Details are below
    http://msdn.microsoft.com/en-us/library/ms525347%28v=vs.90%29.aspx

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

Sidebar

Related Questions

<ItemTemplate> <asp:Label runat=server><%#DataBinder.Eval(Container.DataItem, Question)%></asp:Label> <asp:DropDownList runat=server id=<%#DataBinder.Eval(Container.DataItem, QuestionID)%>>> <asp:ListItem value=1 text=Yes /> <asp:ListItem value=0
i have a datalist control <ItemTemplate> <asp:Label ID=lblAddressID runat=server Text='<%# Bind(StudentName) %>'/> <asp:Label ID=lbl
<asp:Repeater ID=Repeater_RatingQuestions_Individuals runat=server> <ItemTemplate> <asp:Label CssClass=bold center ID=Label1 runat=server Text='<%# DataBinder.Eval(Container.DataItem,Question)%>' /> <asp:Repeater ID=Repeater_RatingAnswers_Individuals
I have a nested gridview: <gridview id=gvParent runat=server > <Columns> <asp:TemplateField> <ItemTemplate> <asp:Label Id=name
I have a ListView with an ItemTemplate item as below: <asp:Label runat=server ID=lblChangeOrders><%#Eval(sum)%></asp:Label> What
This is my datalist: <asp:DataList ID=DataList1 runat=server DataSourceID=SqlDataSource1 RepeatLayout=Flow> <ItemTemplate> <asp:Label ID=IdLabel runat=server Text='<%#
<asp:Repeater ID=Repeater1 runat=server DataSourceID=SqlDataSource1 OnItemDataBound=Repeater1_ItemDatabound> <ItemTemplate> <tr> <td> <%#Eval(Priority) %> </td> <td> <%#Eval(ProjectName) %>
<asp:Repeater ID=rptrParent runat=server> <ItemTemplate> <li> <a href=<% =ResolveUrl(~/cPanel/UserView.aspx?User=)%><%# Eval(StudentUserName) %>> <span> <% ProfileCommon pc
aspx file: <asp:Repeater ID=Repeater_sorular runat=server> <HeaderTemplate> </HeaderTemplate> <ItemTemplate> <div class=div_soru> <div class=div_soru_wrapper> <%#Eval(Subject)%> <asp:RadioButtonList
<asp:UpdatePanel ID=asd runat=server> <ContentTemplate> <asp:GridView ID=gvUpdate runat=server> <Columns> <asp:TemplateField HeaderText=DATE> <ItemTemplate> <asp:Label ID=lblDate runat=server

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.