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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Mants
Frequent Visitor

Conditional formatting background in table based on measure / calculated column

Dear, 

 

I'm creating a table which will have between 30-60 columns and around 25 rows. I would like the background of each cell to be colored based on specific rules (i.e. larger than x and smaller than y then "red"). the idea is to use the field value option to refer to a column/measure that will be able to provide the rules. 

 

To that end i have tried to create several conditional measures and columns, however everytime these stop evaluating after meeting the first condition, making the whole column only one color, regardless of the value in the cells.

 

Is there something wrong in the formulas or in my thinking? 

 

Both the pbix and an excel with the measures/calculation used (in the original work file) are available here: https://we.tl/t-MDiJ7taiYl

 

Using the calculated column works in the table (visible when viewing the table in the background), however using a calculated column for the field value rule only gives first and last as options and uses only one evaluation for the whole column.

 

I would like to avoid manually creating rules per column, and also expect to be adding rules in the future

 

Any help on this would be appreciated

 

 

 

 

 

 

3 REPLIES 3
Anonymous
Not applicable

Hi, @Mants 

May I ask if you have gotten this issue resolved? If it is solved, please share your solution and accept it as solution, it will be helpful for other members of the community who have similar problems as yours to solve it faster.

 

If not, please provide more detailed information about your problem, such as calculation logic, expected results. We will do our best to solve your problem.

 

 

I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Fen Ling,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

lucadelicio
Super User
Super User

Hi @Mants probably you have to start to review your dataset because in your power bi you have 1.020 rows instead of 25 you said.
Create and import the correct dataset then re-publish the pbix to get the help that you need.
Thank you

 



Luca D'Elicio

LinkedIn Profile

Hi Luca, yes that correct thanks for checking.

The end result of that table would be a table visual where Order would be pivoted to columsn (1 to 30). 

Then in that table each cell needs to be formatted, with the challenge presented above.

 

For the purpose of illustration the end result table visual is created with columns 1 to 11

 

 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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