We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

GridGroupingControl Column - HtmlEncode

Thread ID:





75360 Jul 23,2008 04:55 AM UTC Jul 25,2008 12:21 PM UTC ASP.NET Web Forms (Classic) 1
Tags: GridGroupingControl
Kallyani Lanje
Asked On July 23, 2008 04:55 AM UTC

In GridGroupingControl, Is there any column properties for display the data in HtmlEncode format?.

Example in Gridview:

Thank you

Rajarajeswari S [Syncfusion]
Replied On July 25, 2008 12:21 PM UTC

Hi Kallyani,

Thanks for using Syncfusion products.

In our GridGroupingControl an event called, “QueryCellStyleInfo” which will get raised, for each and every cell gets rendered. There we can make change the style attribute of each and every cell, including the CellValue.

Please refer the below code snippet where “HtmlEncode” is applied for a certain column.

protected void GridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e)
if (e.TableCellIdentity.TableCellType == GridTableCellType.RecordFieldCell || e.TableCellIdentity.TableCellType == GridTableCellType.AlternateRecordFieldCell )
if (e.TableCellIdentity.Column.Name == "String")
string text = e.Style.CellValue.ToString();
e.Style.CellValue = Server.HtmlEncode(text);


Please refer the sample from the belwo link which illusatrtes this:


Please have a look at the above and let me know if you have any other concerns.



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon