hi,
can you please provide me with an example on how to use the BetweenXandYConditionalFormatRule by code?
how to give the values??
BetweenXandYConditionalFormatRule br = new BetweenXandYConditionalFormatRule();
br.ShouldRefreshOnDataChange = true;
br.StyleToApply = s;
Hi,
You can use the LowerBound and UpperBound properties of the BetweenXandYConditionalFormatRule to define the range.
http://help.infragistics.com/NetAdvantage/Silverlight/2010.3/CLR4.0/?page=InfragisticsSL4.Controls.Grids.XamGrid.v10.3~Infragistics.Controls.Grids.BetweenXandYConditionalFormatRule_members.html
Regards
is there a sample that shows how?
ooops!
sorry.. i thought that lowerbound and upperbound should be a class derived from IComparable...
my bad..
thanks anyway :)
BetweenXandYConditionalFormatRule r = new BetweenXandYConditionalFormatRule(); Style s = new Style(typeof(ConditionalFormattingCellControl)); s.Setters.Add(new Setter(ConditionalFormattingCellControl.BackgroundProperty, new SolidColorBrush(Colors.Red))); s.Setters.Add(new Setter(ConditionalFormattingCellControl.AltBackgroundProperty, new SolidColorBrush(Colors.Red))); r.StyleToApply = s; r.LowerBound = 3; r.UpperBound = 9; XGrid.Columns.DataColumns["MyColumnKey"].ConditionalFormatCollection.Add(r);
HTH