Spire.XLS is a professional Excel API that enables developers to create, manage, manipulate, convert and print Excel worksheets. Get free and professional technical support for Spire.XLS for .NET, Java, Android, C++, Python.

Thu Nov 10, 2016 4:21 pm

Hi

When i create chart with negative value, this negative value don't have color.
And when i try to set color (ForegroundColor and BackgrounrColor) or uncheck SwapColorsOnNegative it's don't work

Code: Select all
var chart = sheet.Charts.Add();
var series = chart.Series.Add();
series.EnteredDirectlyValues = new object[] { -1, 1 };
series.DataFormat.AreaProperties.SwapColorsOnNegative = false;
series.DataFormat.AreaProperties.ForegroundColor = Color.Blue;


Do you have a workaround ?

Thanks.
Attachments
sample.PNG
sample.PNG (27.81 KiB) Viewed 1741 times

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

Fri Nov 11, 2016 6:32 am

Hello,

Thanks for your inquiry. I have noticed the issue and forworded it to our Dev team. I will inform you if there is any progress.
Sorry for inconvenience.

Sincerely,
Nina
E-iceblue support team
User avatar

Nina.Tang
 
Posts: 1182
Joined: Tue Sep 27, 2016 1:06 am

Fri Jan 06, 2017 7:44 am

Dear VincentB,

Thanks for your waiting.
Please download the Spire.XLS Pack Hotfix Version:7.11.34 at first, and then use the following code to change the color of negative.
Code: Select all
series.InvertNegaColor=true;

Please get it back to us in case of any problem.

Best wishes,
Nina
E-iceblue support team
User avatar

Nina.Tang
 
Posts: 1182
Joined: Tue Sep 27, 2016 1:06 am

Tue Jan 10, 2017 9:09 am

Hi VincentB,

Did you test the code? How is your issue now? I will appreciate it so much if you could give us some feedback.

Best regards,
Nina
E-iceblue support team
User avatar

Nina.Tang
 
Posts: 1182
Joined: Tue Sep 27, 2016 1:06 am

Wed Jan 11, 2017 4:56 pm

Hi,

Yes, it works !!

Thanks

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

Thu Jan 12, 2017 5:39 am

Hi VincentB,

Thanks for your feedback.
Please feel free to contact us if there is any question.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy.jiang
 
Posts: 3099
Joined: Tue Sep 06, 2016 8:30 am

Return to Spire.XLS

cron