Questions about conditionals formats

Technical support for Spire.XLS

Moderators: iceblue support, Flash, Manager

Questions about conditionals formats

Postby VincentB » Tue Aug 29, 2017 4:24 pm

Hello,

I have some questions about conditional formats.

1°) Average
I have find the formatType "Above Average" but i don't found "Below Average"

Code: Select all
var average = rangeSpire.ConditionalFormats.AddCondition();
average.FormatType = ConditionalFormatType.AboveAverage;
//average.FormatType = ConditionalFormatType.BelowAverage;


2°) Top 10
I don't find propertie to set up formatType "Top10" (Top, bottom, rank, percent...),
like DataBar to formatType "DataBar" or IconSet to formatType "IconSet".

Code: Select all
var top = rangeSpire.ConditionalFormats.AddCondition();
top.FormatType = ConditionalFormatType.Top10;


3°) TimePeriod
In formatType "TimePeriod", I do'nt know how set up DateOperator (yesterday, today, tomorrow...)

Code: Select all
var top = rangeSpire.ConditionalFormats.AddCondition();
top.FormatType = ConditionalFormatType.TimePeriod;


For the other conditions, I managed to do what I wanted :)

Thanks
VincentB
 
Posts: 78
Joined: Thu Sep 15, 2016 9:44 am

Re: Questions about conditionals formats

Postby Betsy.jiang » Wed Aug 30, 2017 7:19 am

Dear VincentB,

Thanks for your inquiry.
Sorry that Spire.XLS doesn't support the three settings at present. But they have been implemented, just not include into current hotfix. We will let you know when the hotfix is available.
In addition, for the third requirement, here is another way to achieve same result at present, that is formula.
Code: Select all
            ConditionalFormatWrapper format = sheet.Range["E1:E8"].ConditionalFormats.AddCondition();
            format.FormatType = ConditionalFormatType.Formula;
            //modify the formula according to your specific requirement.
            format.FirstFormula = "=$E1=TODAY()";
            format.FontColor = Color.Red;


Sincerely,
Betsy
E-iceblue support team
User avatar
Betsy.jiang
 
Posts: 1424
Joined: Tue Sep 06, 2016 8:30 am

Re: Questions about conditionals formats

Postby VincentB » Wed Aug 30, 2017 8:21 am

Hello,

Ok thanks for your reply,
Waiting for hotfix,

Thanks
VincentB
 
Posts: 78
Joined: Thu Sep 15, 2016 9:44 am


Return to Spire.XLS

Who is online

Users browsing this forum: No registered users and 1 guest