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.
Syncfusion Feedback

Accessing Cell's Conditional Formatting Color Scale value

Thread ID:

Created:

Updated:

Platform:

Replies:

125074 Jul 19,2016 09:16 PM UTC Jul 21,2016 06:46 AM UTC UWP 3
loading
Tags: XlsIO
Travis Schilling
Asked On July 19, 2016 09:16 PM UTC

Does anyone know of a way to programatically get the Conditional Formatting color of a cell, specifically from Color Scales?

Using IRange.CellStyle.Color I can get the fill color of a cell. However if the user has created a Conditional Formatting Color Scales I haven't been able to figure out how to get the cell color.

I've figured out that IRange.ConditionalFormats gives me access to the information about the conditional formats and I can interrogate each individually. I can also use the IConditionalFormat.FormatType to determine if it is a ColorScale. I was hoping that there was a property that would just provide me color, but since I don't see that I tried to go the route of calculating it.

I've attached a really simple example excel workbook that has 6 formatted cells. Using IConditionalFormat.ColorScale.Criteria I believed that I could try to compare the cell text to the Criteria's Value using the Operator and then know which color. However, even though I have 6 unique colors I'm only getting 3 criteria.

tl;dr: Is there property that provides the cell color being set by Conditional Formatting, if not is there a way to figure it out and specifically for ColorScale Conditional Formatting?

Thanks,
Travis

Attachment: Book1_87b56ac9.zip

Kesavan D [Syncfusion]
Replied On July 20, 2016 07:20 AM UTC

Hi Travis, 
  
XlsIO doesn’t have support to calculate and return color scale value of a cell and have logged feature report regarding this. A support incident to track the status of this feature has been created under your account. Please log on to our support website to check for further updates 
  
  
Please let me know if you have any questions. 
  
Regards, 
Kesavan 


Travis Schilling
Replied On July 20, 2016 04:16 PM UTC

Thanks for the quick response Kesavan!

Bummer that it doesn't have it. Hopefully there will be bandwidth in the future for them to cover this feature, but I appreciate knowing so I didn't spend more time searching.

Thanks again,
Travis

Kesavan D [Syncfusion]
Replied On July 21, 2016 06:46 AM UTC

Hi Travis, 

Sorry to disappoint you, you can track the information about this feature implementation in the support incident which is created under your account.  

Regards, 
Kesavan 


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.

Warning Icon 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.Close Icon

;