Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
DarshanKumar
Helper II
Helper II

Multiple Button Bookmarks - Need Help

Hi,

 

I have a requirement to show the attrition in a matrix visual for last 12 months and year to date, I was able to achieve this using bookmarks, now I have additonal requirement to show the  leavers headcount by last 12 month leavers & year to date , is there a way bookmarks can be configured to show visuals based on multipe button selection.

DarshanKumar_0-1748557814306.png

So the requirement is that the matrix visual should change to either attrition or headcount based on the either YTD or LTM button selection.

 

Regards,

Darshan

1 ACCEPTED SOLUTION

Hi @DarshanKumar,

 

Thank you for reaching out to Microsoft Fabric Community.

 

Based on your requirement, please follow below steps:

  • Create two independent tables:

    PeriodSelector = DATATABLE("Period", STRING, {{"YTD"}, {"LTM"}})

    MetricSelector = DATATABLE("Metric", STRING, {{"Headcount"}, {"Attrition"}})

Add these both tables to the report as slicers and format them as buttons.

 

  • Create a new measure like below:

    SelectedMetricMeasure =

    VAR _Metric = SELECTEDVALUE(MetricSelector[Metric])

    VAR _Period = SELECTEDVALUE(PeriodSelector[Period])

    RETURN

        SWITCH(

            TRUE(),

            _Metric = "Headcount" && _Period = "YTD", [Headcount_YTD],

            _Metric = "Headcount" && _Period = "LTM", [Headcount_LTM],

            _Metric = "Attrition" && _Period = "YTD", [Attrition_YTD],

            _Metric = "Attrition" && _Period = "LTM", [Attrition_LTM],

            BLANK()

        )

Use this measure in the matrix visual, the data will update automatically based on both slicer selections.

 

If this post helps, then please consider Accepting as solution to help the other members find it more quickly, don't forget to give a "Kudos" – I’d truly appreciate it! 

 

Thanks and regards,

Anjan Kumar Chippa

View solution in original post

3 REPLIES 3
DarshanKumar
Helper II
Helper II

Thanks Pankaj.

 

But the requirement is show the matrix visual based on two filter. Ex

 

The matrix should show YTD headcount when we select YTD button and Headcount button.

 

I want to check if this possible if not I can have  4 buttons bookmarked to each visual Ex: HC YTD, HC LTM, Attriton YTD and Attriton LTM.

 

Regards,

Darshan

Hi @DarshanKumar,

 

Thank you for reaching out to Microsoft Fabric Community.

 

Based on your requirement, please follow below steps:

  • Create two independent tables:

    PeriodSelector = DATATABLE("Period", STRING, {{"YTD"}, {"LTM"}})

    MetricSelector = DATATABLE("Metric", STRING, {{"Headcount"}, {"Attrition"}})

Add these both tables to the report as slicers and format them as buttons.

 

  • Create a new measure like below:

    SelectedMetricMeasure =

    VAR _Metric = SELECTEDVALUE(MetricSelector[Metric])

    VAR _Period = SELECTEDVALUE(PeriodSelector[Period])

    RETURN

        SWITCH(

            TRUE(),

            _Metric = "Headcount" && _Period = "YTD", [Headcount_YTD],

            _Metric = "Headcount" && _Period = "LTM", [Headcount_LTM],

            _Metric = "Attrition" && _Period = "YTD", [Attrition_YTD],

            _Metric = "Attrition" && _Period = "LTM", [Attrition_LTM],

            BLANK()

        )

Use this measure in the matrix visual, the data will update automatically based on both slicer selections.

 

If this post helps, then please consider Accepting as solution to help the other members find it more quickly, don't forget to give a "Kudos" – I’d truly appreciate it! 

 

Thanks and regards,

Anjan Kumar Chippa

pankajnamekar25
Super User
Super User

Hello @DarshanKumar 

Try this

 Create a Field Parameter for Metrics:

Go to Modeling → New Parameter → Fields.

Name it MetricSelector

Add fields like:

Headcount_YTD

Headcount_LTM

Attrition_YTD

Attrition_LTM

 Create a Slicer using MetricSelector

Style it as buttons or drop-down.

Use MetricSelector in the Matrix Values

The matrix will update based on the selection.

Thanks,
 Pankaj Namekar | LinkedIn

If this solution helps, please accept it and give a kudos (Like), it would be greatly appreciated.

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.