GGC + GridConditionalFormatDescriptor

Hello,

i've got a object called Appointment.
Every Appointment has a property (nested object) called Status. Now i've bound a list of Appointments to my GGC and want to have a conditional Format on a value of Appointment.Status.XXX .

here's my Expression:
[Status_XXX] LIKE 'YYY'

Status_XXX is the Mappingname of the column...
But this dosn't work.

Could anyone please help me?

Regards
Tobias



1 Reply

NA Nisha Arockiya A Syncfusion Team December 11, 2008 12:32 PM UTC

Hi Tobias,

Thanks for your interest in Syncfusion Products.

You can use Expression property of GridConditionalFormatDescriptor class to specify the ConditionalFormats.

Please try code like this:

GridConditionalFormatDescriptor Descriptor1 = new GridConditionalFormatDescriptor();
Descriptor1.Appearance.AnyRecordFieldCell.Enabled = false;
Descriptor1.Appearance.AnyRecordFieldCell.BackColor = Color.Orange;
Descriptor1.Expression = "(([Col1] Like "CRiDRS") or ([Col1] Like "CRANE"))And (([Col2] Like "Market Data") or ([Col2] Like "Credit Data"))";
this.gridGroupingControl1.TableDescriptor.ConditionalFormats.Add(Descriptor1);

Here is a small sample:
http://websamples.syncfusion.com//samples/Grid.Windows/Development/GGC_ConditionalFormating_String.zip

Please let me know if this helps.

Regards,
Nisha



Loader.
Up arrow icon