DAX for Power BI - Highlight Current Period

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ธ.ค. 2024

ความคิดเห็น • 27

  • @IgorAntarov
    @IgorAntarov 4 ปีที่แล้ว +1

    That's helped me a lot, thanks! To use it for highlighting past periods, just change "-" to ">=" in the code, like this:
    IsFuturePeriod =
    VAR CurrentPeriod = MAX('SuC Projects By Month Filled'[Date])
    RETURN
    IF(
    DATE(YEAR(CurrentPeriod),MONTH(CurrentPeriod),1) >= DATE(YEAR(TODAY()),MONTH(TODAY()),1),
    1,
    0
    )

  • @ymohamed3154
    @ymohamed3154 2 ปีที่แล้ว

    Great video. Can also use this conditional formatting for the names of the X-axis (Jan, Feb, Mar, ...) ? Thanks

  • @simonmarston8750
    @simonmarston8750 5 ปีที่แล้ว

    Nice tip. I have a scenario where I have a customer table that has a date column for sales uplift estimate date. Using a bar chart I want to be able to filter on a customer and the conditional formatting to highlight the sales uplift estimated month rather than the current month. How would I go about modifying the dax code?Thanks.

  • @jasondavidson2239
    @jasondavidson2239 5 ปีที่แล้ว

    Hi Parker, great video! If I wanted to highlight the most recent entry selected in the date range, which won't always be today(), is that possible? I'm basically looking to apply conditional formatting based on MAX and MIN targets for the Amount but only apply this formatting the most recent column in the bar chart.

  • @didijaba
    @didijaba 5 ปีที่แล้ว +1

    Nice one, I used same approach for table background color, but I didn't think of using it on bar charts. Good job

    • @BIElite
      @BIElite  5 ปีที่แล้ว +1

      Thanks Tomislav!

  • @christopherflynn9811
    @christopherflynn9811 4 ปีที่แล้ว

    How would you go about highlighting a column using a selected value? and everything thats not selected is grey'd out?

  • @agustinmisaza
    @agustinmisaza 5 ปีที่แล้ว

    Great video! Is it possible when you have two variables in a Bar chart, to use Conditional Formating, so if a value is greater compared to the other value it changes color?

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      Hey Agustin! This is possible by creating another measure that compares your two values. You can then use this new measure in your conditional formatting!

  • @srinivasreddysingireddy536
    @srinivasreddysingireddy536 5 ปีที่แล้ว +2

    here you go......one more great tip...!! thank you so much....!!!

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      Haha thank you!

  • @MichaelRygaard
    @MichaelRygaard ปีที่แล้ว

    A VERRY important notice here is that you should use the Date IN the table you want this measure to work on NOT your connected Calendar in your model

  • @dasrotrad
    @dasrotrad 5 ปีที่แล้ว +1

    THAT!!! is slick. Thank you.

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      Thanks Robert!

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      @@tarunr666 Whoa that is awesome! I had no idea. I wish I could append on to this video... Or maybe that can be the next video on the channel. Thanks for the tip, Tarun!

  • @Joeldsnm
    @Joeldsnm 5 ปีที่แล้ว

    It is reverted for me 1 shows the as old months and 0 as current?

    • @Joeldsnm
      @Joeldsnm 5 ปีที่แล้ว

      I figured it out! Your equals signs look like a minus sign! So I kept inserting the minus sign rather than equals in the IF statment.

  • @123jamalq
    @123jamalq 5 ปีที่แล้ว +1

    Excellent tip, thanks

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      Sweet, thanks Jamal!

  • @mehdihammadi6145
    @mehdihammadi6145 5 ปีที่แล้ว +1

    Very useful. thx for sharing

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      Thanks Mehdi!

  • @JonathanCHANAL
    @JonathanCHANAL 5 ปีที่แล้ว +1

    Awesome, thx for sharing so much good tips and tricks ;)

    • @BIElite
      @BIElite  5 ปีที่แล้ว +1

      I appreciate the support, Jonathan!

  • @myazigi
    @myazigi 5 ปีที่แล้ว +1

    Cool!!!! Thanks!!

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      Thanks for watching Mauricio!

  • @majdyazigi8185
    @majdyazigi8185 5 ปีที่แล้ว

    Great one

    • @BIElite
      @BIElite  5 ปีที่แล้ว

      +Majd Yazigi Thanks! Glad you liked it