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.
Unfortunately, activation email could not send to your email. Please try again.

Compare and Format a cell from GroupingGrid

Thread ID:

Created:

Updated:

Platform:

Replies:

71830 Feb 14,2008 10:48 PM Feb 15,2008 04:54 AM Windows Forms 1
loading
Tags: Grouping
umesh Yelgaonkar
Asked On February 14, 2008 10:48 PM

Hi,
I am currently using syncfusions Grouping grid control. While displaying data we want to compare data froma perticualr cell and depending upon condition we want to change background color and tooltip for a particular cell of the grouping grid.



Vishnu Kumar [Syncfusion]
Replied On February 15, 2008 04:54 AM

Hi Umesh

Thank you for your patience.

Issue:Compare and Format a cell from GroupingGrid

You can compare the cell values and apply the background color and Tooltip of the particular row using the below code snippet :


GridConditionalFormatDescriptor gcfd1 = new GridConditionalFormatDescriptor();
gcfd1.Name = "Criteria1";
switch (ProductID.SelectedItem.ToString())
{
case "Equals":
{
gcfd1.Expression = "[ProductID]=" + this.DDLPid.SelectedItem.Text;
break;
}
}
Color c1 = Color.FromName(colorProduct.SelectedItem.Text);
gcfd1.Appearance.AnyRecordFieldCell.BackColor = c1;
gcfd1.Appearance.AnyRecordFieldCell.CellTipText = "ProductCell";
this.GridGroupingControl1.TableDescriptor.ConditionalFormats.Add(gcfd1);


Please refer the sample in the below link which illustrates the above:

http://websamples.syncfusion.com/samples/Grid.Web/6.1.0.34/71830/main.htm

Please try running the above sample and let me know if this helps.

Regards,
Vishnu.




CONFIRMATION

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.

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.

;