Forum Discussion

LukeDurrant's avatar
LukeDurrant
Frequent Visitor
2 years ago
Solved

YTD Line Graph

I want my YTD line graph to show Jan-Oct when Oct is selected on the slicer but it is only showing data for October?

 

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi LukeDurrant 

     

    I ran the testing as follows.

     

    My sample:

     

     

    Create a measure as follows

    Measure = IF(MONTH(MAX('Table'[Date])) <= MONTH(SELECTEDVALUE('Date'[Date])), 1, 0)

     

    Put the measure into the visual-level filters, set up show items when the value is 1.

    Is this the result you expect?

     

    Best Regards,
    Community Support Team _Yuliax

     

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

    YTD Line Graph.pbix56 KB

3 Replies

  • LukeDurrant's avatar
    LukeDurrant
    Frequent Visitor

    Is it possible to change it so that i only have to select oct to show Jan - Oct?

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi LukeDurrant 

     

    I ran the testing as follows.

     

    My sample:

     

     

    Create a measure as follows

    Measure = IF(MONTH(MAX('Table'[Date])) <= MONTH(SELECTEDVALUE('Date'[Date])), 1, 0)

     

    Put the measure into the visual-level filters, set up show items when the value is 1.

    Is this the result you expect?

     

    Best Regards,
    Community Support Team _Yuliax

     

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

    YTD Line Graph.pbix56 KB