<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Conditional formatting using dax in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135009#M49014</link>
    <description>&lt;P&gt;This one is also not working!!&lt;/P&gt;</description>
    <pubDate>Thu, 14 Oct 2021 12:35:55 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2021-10-14T12:35:55Z</dc:date>
    <item>
      <title>Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134755#M48999</link>
      <description>&lt;P&gt;I want &lt;STRONG&gt;Grey&lt;/STRONG&gt; backgroung color where the matrix values are blank.&amp;nbsp;&lt;/P&gt;&lt;P&gt;For that I wrote following measure but I am not getting desired output.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;format= &lt;/SPAN&gt;&lt;SPAN&gt;SWITCH&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;True&lt;/SPAN&gt;&lt;SPAN&gt;(),&lt;/SPAN&gt;&lt;SPAN&gt;SELECTEDVALUE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Employee Data'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;)=&lt;/SPAN&gt;&lt;SPAN&gt;TODAY&lt;/SPAN&gt;&lt;SPAN&gt;(),&lt;/SPAN&gt;&lt;SPAN&gt;"Yellow"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;SELECTEDVALUE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Employee Data'[Actual Hours]&lt;/SPAN&gt;&lt;SPAN&gt;)&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;4.5&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;SELECTEDVALUE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Employee Data'[Actual Hours]&lt;/SPAN&gt;&lt;SPAN&gt;)&amp;gt;=&lt;/SPAN&gt;&lt;SPAN&gt;4&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;"LightBlue"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;SELECTEDVALUE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Employee Data'[Actual Hours]&lt;/SPAN&gt;&lt;SPAN&gt;)=&lt;/SPAN&gt;&lt;SPAN&gt;BLANK&lt;/SPAN&gt;&lt;SPAN&gt;(),&lt;/SPAN&gt;&lt;SPAN&gt;"Grey"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Matrix:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;img /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;Can someone help!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 10:44:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134755#M48999</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-10-14T10:44:08Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134937#M49008</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you try below code:-&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;format =
IF (
    MAX ( 'Employee Data'[Date] ) = TODAY (),
    "Yellow",
    IF (
        MAX ( 'Employee Data'[Actual Hours] ) &amp;lt; 4.5
            &amp;amp;&amp;amp; MAX ( 'Employee Data'[Actual Hours] ) &amp;gt;= 4,
        "LightBlue",
        IF ( MAX ( 'Employee Data'[Actual Hours] ) = BLANK (), "Grey" )
    )
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Samarth&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 12:01:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134937#M49008</guid>
      <dc:creator>Samarth_18</dc:creator>
      <dc:date>2021-10-14T12:01:39Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134945#M49009</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312802" data-lia-user-login="Samarth_18" class="lia-mention lia-mention-user"&gt;Samarth_18&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried that code but its not working for blank values!!&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 12:04:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134945#M49009</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-10-14T12:04:22Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134965#M49011</link>
      <description>&lt;P&gt;can you try below code:-&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;format =
VAR selected_date =
    MAX ( 'Employee Data'[Date] )
RETURN
    IF (
        ISBLANK ( selected_date ),
        "Grey",
        IF (
            selected_date = TODAY (),
            "Yellow",
            IF ( selected_date &amp;lt; 4.5 &amp;amp;&amp;amp; selected_date &amp;gt;= 4, "LightBlue" )
        )
    )&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 14 Oct 2021 12:12:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2134965#M49011</guid>
      <dc:creator>Samarth_18</dc:creator>
      <dc:date>2021-10-14T12:12:38Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135009#M49014</link>
      <description>&lt;P&gt;This one is also not working!!&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 12:35:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135009#M49014</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-10-14T12:35:55Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135092#M49018</link>
      <description>&lt;P&gt;Is it possible for you to share PBIX file after removing confidential data?&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 13:25:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135092#M49018</guid>
      <dc:creator>Samarth_18</dc:creator>
      <dc:date>2021-10-14T13:25:55Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135154#M49019</link>
      <description>&lt;P&gt;&lt;A href="https://inkeysolutions0-my.sharepoint.com/:u:/g/personal/shweta_dalal_inkeysolutions_com/EUji0PMUhixDgMk35URT7pMBK8AHGWSQ3V-TO6jISvBZ2w?e=helWN1" target="_blank"&gt;https://inkeysolutions0-my.sharepoint.com/:u:/g/personal/shweta_dalal_inkeysolutions_com/EUji0PMUhixDgMk35URT7pMBK8AHGWSQ3V-TO6jISvBZ2w?e=helWN1&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 13:49:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135154#M49019</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-10-14T13:49:56Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional formatting using dax</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135270#M49025</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;Actually matrix visual not consider blank value for conditional formating when we use F&lt;STRONG&gt;ormat by as field value&lt;/STRONG&gt; . So we need to do one work around.&lt;/P&gt;&lt;P&gt;1. Update your Actual date column code with below code:-&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Actual Hours =
VAR result =
    IF ( WEEKDAY ( 'Employee Data'[Date], 2 ) &amp;lt;= 5, 'Employee Data'[Hours Worked] )
RETURN
    IF ( result = BLANK (), 0, result )&lt;/LI-CODE&gt;&lt;P&gt;2. Update your conditional formatting code with below code:-&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Conditional Formatting = 
IF(
    SELECTEDVALUE('Employee Data'[Date])=TODAY(),
    "#E7F508",
    IF(
        SELECTEDVALUE('Employee Data'[Actual Hours])&amp;lt;4.5 &amp;amp;&amp;amp; SELECTEDVALUE('Employee Data'[Actual Hours])&amp;gt;=4,
        "#08BCF5",
        IF(
            SELECTEDVALUE('Employee Data'[Actual Hours]) = 0,
        "#859CA4"
        )
    )
)&lt;/LI-CODE&gt;&lt;P&gt;You will see below output:-&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 14:34:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Conditional-formatting-using-dax/m-p/2135270#M49025</guid>
      <dc:creator>Samarth_18</dc:creator>
      <dc:date>2021-10-14T14:34:09Z</dc:date>
    </item>
  </channel>
</rss>

