Forum Discussion

Imagauthamam's avatar
Imagauthamam
Helper III
9 months ago
Solved

Bookmark Interaction Issue — Second-Level Bookmark Not Resetting Correctly

Scenario Overview I’m working on a Power BI report that uses multiple bookmarks for navigation. There are two levels of bookmarks: 1️⃣ Top-Level Bookmark: Used to switch between Revenue, Profit, ...
  • ToddChitt's avatar
    9 months ago

    Hello Imagauthamam 

    Bookmarks can be tricky. 

    When I read your note about "top level bookmarks" controlling Revenue, Profit, or Cost, I thought that maybe you should try the SELECTEDMEASURE approach:

    1) Create the three measures you need, which I suppose you already have.

    2) Create calculated column:

    Select Measure =
    DATATABLE (
        "Measure", STRING,
        {
            { "Revenue" },
            { "Profit" },
            { "Costs" }
        }
    )

    3) Create a Measure: 

    Selected Measure = SWITCH(SELECTEDVALUE('Select Measure'[Measure]), "Revenue", [Revenue], "Profit", [Profit], "Costs", [Costs])
     
    Put a slicer on the page. Use the [Measure] column. Set it up a Button Slicer
    Set up ONE set of visuals (charts, etc.) and use the [Selected Measure] as the Value column.
     
    4) Optional: Create a Measure to be used for Chart Title: 
    My Chart Title = SELECTEDVALUE('Select Measure'[Measure]) & " Used as Chart Title"
    5) For the Chart title, use a function as the title text. Select "Field Value" as the Format Style, and  [My Chart Title] for "What fiueld should we base this on?
     
     
    Now you're down to ONE set of Bookmarks.