Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Dalla_Terra
Helper I
Helper I

Conditional Formatting Data Colors for Negative Numbers

I am trying to configure my visualization online so that negative percentages are red and positive are green. I feel like I have the conditional formatting set right but the visual is wrong.

Screen Shot 2020-10-19 at 12.30.10 PM.pngScreen Shot 2020-10-19 at 12.30.35 PM.png

1 ACCEPTED SOLUTION
Sumanth_23
Memorable Member
Memorable Member

hi @Dalla_Terra - You can try the option to not set the values for the upper and lower limits highted in the below screenshot.

Just leave these values BLANK and Power BI will idenitify the limits based on the range of values available in your data. 

 

Sumanth_23_0-1603339737450.png

Please mark the above comment as a solution to help others find it more quickly. Also please provide a 👍 if my comment helped with solving your issue. Thanks!

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!

Proud to be a Super User!



View solution in original post

7 REPLIES 7
Sumanth_23
Memorable Member
Memorable Member

hi @Dalla_Terra - You can try the option to not set the values for the upper and lower limits highted in the below screenshot.

Just leave these values BLANK and Power BI will idenitify the limits based on the range of values available in your data. 

 

Sumanth_23_0-1603339737450.png

Please mark the above comment as a solution to help others find it more quickly. Also please provide a 👍 if my comment helped with solving your issue. Thanks!

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!

Proud to be a Super User!



Thanks @Sumanth_23 this worked beautifully and it was a very simple solve, much appreciated! 

@Dalla_Terra  - Happy to help! 🙂

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!

Proud to be a Super User!



V-lianl-msft
Community Support
Community Support

Hi @Dalla_Terra ,

 

Try to create a measure like this then apply it to conditional formatting:

IF([YTD VAR%]>0,"green","red")

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks for the help. I like to creative approach but I didn't try it because I wanted to avoid creating another measure on top of the percent measure I was already using. 

collinq
Super User
Super User

HI @Dalla_Terra ,

 

I think that the issue may be in the formula, your conditional formatting is set to "number" and you data is set to "percent".  I think that you need to modify the color to be less than -9999 and less than 0.  And the other one be greater/equal to 0 and less than 99999.   OR, change those to percentages.  If you change to percentages, just make sure that your data really is a percentage.

 

I would appreciate Kudos if my response was helpful. I would also appreciate it if you would Mark this As a Solution if it solved the problem. Thanks!



Did I answer your question? Mark my post as a solution!

Proud to be a Datanaut!
Private message me for consulting or training needs.




Thanks for the reply. I tried your appraoch but it would not accept me changing the number to a percent with the inputs your recommended. I appreciate the help. 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors