- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I don't want to involve blank cells in my measure
I'm now doing a internship so im a noob with Power BI. the thing is, on the left i have hours and on the right the standard worktime. i want to show if someone goes over the standard worktime it will turn red. but now even if its blank it turns red. im new with dax. what i did was if hours - worktime >= turn green otherwise red:
can someone please help im wiasting too much time.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Anonymous ,
Try this measure:
Measure = IF(SELECTEDVALUE('Table'[hours])-SELECTEDVALUE('Table'[standard worktime])>=0,"#FF0000","#00FF1E")
And this is my conditional formatting:
You can also refer to my pbix file for better understanding.
Best regards,
Community Support Team Selina zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for your answer i really appreciate it, but the thing is i want the blank fields to not be included in the measure. so i want the rows that dont have a working time to be the same as before. if i look at what you did i still see the second row (in your printscreen) turning red while there is no working time. i tried your measure but i get the same result as mine....
Kind regards,
TD
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Anonymous ,
If you don't want the blank row, you can directly filter it out, like this:
Please check the pbix file I uploaded above to make sure it is not different from your process.
Best regards,
Community Support Team Selina zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, thanks for your reply i really appreciate it!
the thing is i dont want the blank rows to be involved in the maesure. so if there is a blank standard working time, then i want hours not to be involved to any measure or condition. so it will be the same colour and still shows hours.
so for you to understand i want this:
i hope you understand what i want to do.
thankyou for your reply!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry i mean i want it like this

Helpful resources
Join us at the Microsoft Fabric Community Conference
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Power BI Monthly Update - February 2025
Check out the February 2025 Power BI update to learn about new features.

Subject | Author | Posted | |
---|---|---|---|
07-03-2024 05:34 AM | |||
09-24-2024 02:27 AM | |||
09-18-2024 06:29 AM | |||
10-07-2024 04:12 PM | |||
05-24-2023 01:55 AM |
User | Count |
---|---|
26 | |
12 | |
11 | |
9 | |
9 |
User | Count |
---|---|
17 | |
14 | |
13 | |
13 | |
12 |