Forum Discussion

afkhalifeh's avatar
afkhalifeh
Frequent Visitor
2 years ago
Solved

Changing Visual Title Dynamically-Power BI Desktop

Hi,

I have around 35 visuals; I need a way to change the title dynamically of each visual based on the selected value for a slicer and based on the visual name itself.

For example, the title of the visual one must be “No. of students” if the selected slicer is “en”, whereas the title of visual one must be “No. of students in French” if the selected slicer is “fr”.

For the 2nd visual, the title of visual must be “No. of customers” if the selected slicer is “en”, whereas the title of this visual must be “No. of customers in French Language” if the selected slicer is “fr”. and so on.

 

Please note that the titles are saved in a table. The table contains the following columns: LanguageID, VisualID, Title.

 

I am looking for a solution (one measure) for all of the 35 visuals?

 

Thank you,

Abdul

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi afkhalifeh 

    You can refer to the following solution.

    I create the following sample tables.

    Slicer table.

    Title Table

    Data table

    Create a relationship between slicer table and language table.

    Then when create each visual, put the visual id to the visual filter. 

    e.g I create two visuals column visual and pie chart visual, in column visual, i filter the column visual equal to 1, and the pie chart equal to 2.

     

     

    Then set each title to the following. select the title column.

     

     Output

     

    Best Regards!

    Yolo Zhu

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

     

     

     

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi afkhalifeh 

    You can refer to the following solution.

    I create the following sample tables.

    Slicer table.

    Title Table

    Data table

    Create a relationship between slicer table and language table.

    Then when create each visual, put the visual id to the visual filter. 

    e.g I create two visuals column visual and pie chart visual, in column visual, i filter the column visual equal to 1, and the pie chart equal to 2.

     

     

    Then set each title to the following. select the title column.

     

     Output

     

    Best Regards!

    Yolo Zhu

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