Hi Nikolay,
I was able to get it working fine from code behind using System.Web.HttpUtility.HtmlEncode.
The problem with this approach is that I will have to modify the data collection already returned by the business layer, so I would probably opt for implementing this on JS.
I hit a wall trying to use JS.
With the following code I am able to see the data and display it modified on an alert but the grid does not reflect the change.
function RadGrid1_RowDataBound(sender, args)
{
args.get_dataItem()["Name"] = escape(args.get_dataItem()["Name"]);
alert(args.get_dataItem()["Name"]);
}
If I use something like this:
function RadGrid1_RowDataBound(sender, args)
{
args.get_item().get_cell("Name").innerHTML = escape(args.get_dataItem()["Name"]);
}
I can see the modified data on the grid but encoded as %3c..., etc.
What would be the correct approach to change the cell data on this event?
Thanks.