Forum Discussion
Dynamic measure based on selection slicer
- 3 years ago
Hi , Pallavi_m
According to your description, you want to "if jan 2022 is selected in the slicer, then measure has to return jan2022."
Here are the steps you can refer to :
(1)We can create a measure:
Measure = var _slicer_date=SELECTEDVALUE('Table'[monthyear]) return FORMAT(_slicer_date,"mmm yyyy")(3)Then we put the [monthyear] on the slicer visual and the measure on the card visual and we will meet your need :
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi amitchandak . Thanks for the quick reply.Could you eloborate more.
Requirement: measure has to be created on the slicer selection.
Measure returns just the monthyear column value i.e., if jan 2022 is selected in the slicer, then measure has to return jan2022.
Hope I'm clear.
Hi , Pallavi_m
According to your description, you want to "if jan 2022 is selected in the slicer, then measure has to return jan2022."
Here are the steps you can refer to :
(1)We can create a measure:
Measure = var _slicer_date=SELECTEDVALUE('Table'[monthyear])
return
FORMAT(_slicer_date,"mmm yyyy")
(3)Then we put the [monthyear] on the slicer visual and the measure on the card visual and we will meet your need :
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly