The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I want to create a single tooltip for mutliple cards on which when hover they change the values feild of the tooltip to the field in the card.As seen in the image I want to display the same type of tooltip for all the cards in a single tooltip page with there respective fields.But I have added the fields on the 'show tooltips on' options but it shows the same Revenue field instaed of the card's field in which I hover.
Hi @Deepesh153,
I hope this information is helpful. Please let me know if you have any further questions or if you'd like to discuss this further. If this answers your question, kindly "Accept as Solution" and give it a 'Kudos' so others can find it easily.
Thank you,
Pavan.
Hi @Deepesh153,
I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If my response has addressed your query, please "Accept as Solution" and give a 'Kudos' so other members can easily find it.
Thank you,
Pavan.
Hi @Deepesh153,
Thank you for reaching out in Microsoft Community Forum.
Thank you @danextian, @DataNinja777 for the helpful response.
As suggested by danextian, DataNinja777, I hope this information was helpful. Please let me know if you have any further questions or you'd like to discuss this further. If this answers your question, please "Accept as Solution" and give it a 'Kudos' so others can find it easily.
Please continue using Microsoft community forum.
Regards,
Pavan.
Hi @Deepesh153
The simplest solution is to, instead of the actual measures in your card, use field parameters and just visually filter the card by the field parameter name - https://learn.microsoft.com/en-us/power-bi/create-reports/power-bi-field-parameters
Your tooltip will also need to use the field parameters.
Notice that the tooltip name changes from Total Revenue to Total Transactions and vice-versa.
Please see the attached sample pbix
Hi @Deepesh153 ,
To create a single tooltip for multiple cards in Power BI that dynamically changes based on the hovered field, start by creating a dedicated tooltip page. Rename this page to something like "Tooltip" and in the Format Pane, under Page Information, set the Page Type to Tooltip. Next, add a Card Visual to the tooltip page but do not assign any static fields. Instead, create a DAX measure that dynamically selects the relevant field based on what is being hovered over.
A simple measure for selecting a single field can be written as:
Tooltip Value = SELECTEDVALUE('Table'[Revenue])
However, if multiple fields such as Revenue, ADR, and Occupancy% need to be dynamically displayed, use a more flexible measure:
Tooltip Value =
VAR RevenueCheck = HASONEVALUE('Table'[Revenue])
VAR ADRCheck = HASONEVALUE('Table'[ADR])
VAR OccupancyCheck = HASONEVALUE('Table'[Occupancy%])
RETURN
SWITCH(
TRUE(),
RevenueCheck, SELECTEDVALUE('Table'[Revenue]),
ADRCheck, SELECTEDVALUE('Table'[ADR]),
OccupancyCheck, SELECTEDVALUE('Table'[Occupancy%]),
BLANK()
)
After creating this measure, assign it to the Card Visual on the tooltip page. This ensures that the tooltip dynamically updates to show the correct value based on what is hovered over. Next, go back to the main report page, select each card visual, and in the Format Pane, under Tooltip, set the Tooltip Page to "Tooltip" and turn on Keep all filters to maintain proper context.
If the tooltip does not dynamically update as expected and still shows only one field (e.g., Revenue), check that the dataset columns have proper relationships and that the HASONEVALUE condition correctly detects the hovered field. Also, ensure that the tooltip page has Keep all filters enabled. This method allows a single tooltip to dynamically display different values based on the field in the hovered card.
Best regards,
User | Count |
---|---|
74 | |
70 | |
39 | |
30 | |
28 |
User | Count |
---|---|
104 | |
95 | |
51 | |
48 | |
46 |