Forum Discussion
Eliminating "first/external" filter in tooltip page
Thanks AlexisOlson
We need to use 1 (or a couple) generic measure for all visuals. If we customize the measure to each visual like in your example, we'd have 100s of measures in the report
I'm only suggesting two measures, not one per visual.
If you augment your example to several more visuals, I can show you how to use these two generically.
- AlB2 years ago
Community Champion
You are hardcoding the title for the visual in the code for the measures. How would you generalize the measures with that?
Attaching a new pbix with more visuals
Thanks
- AlexisOlson2 years ago
Super User
The idea is to hardcode the visual type (Main vs Tooltip) rather than the title. To make it work, you need to augment your TitlesT table to a couple additional columns to make the logic work.
I've included a couple of variations of the tooltip measure that should work generically so you can use whichever you prefer.
If you want to use EnligshTitle as your filter on the main visual,TitleTTip = CALCULATE ( CONCATENATEX ( TitlesT, TitlesT[TranslatedTitle], "," ), ALL ( TitlesT[EnglishTitle] ), VALUES ( TitlesT[ID] ), TitlesT[Type] = "TTip" )If you want to use ID as the filter on the main visual,
TitleTTip2 = CALCULATE ( CONCATENATEX ( TitlesT, TitlesT[TranslatedTitle], "," ), TitlesT[Type] = "TTip" )Notes:
- I used CONCATENATEX because it's easier to debug and is the same as SELECTEDVALUE for a single value.
- Instead of a numeric ID column, you could have a descriptive field that associates the main and tooltip titles.