- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dynamic Text in Text Box or Card based on slicer selection
I am trying to change the text in a text box or card based on a slicer selection.
For example, if i select a country "Afghanistan", I want the text box to read "The War in Afghanistan began in 2001". If I select "Ukraine", I want the text to read "Ukraine was attacked in early 2022", and so on.
I've seen similar inquiries with "VAR, RETURN, IF" DAX solutions, but I can't seem to get them to work.
The column name is "Country of origin" and table name is "Orgin/Destination"
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You could probably do something along the lines of a measure with:
TextBoxText =
Lookupvalue(Table[Origin/Destination]),Table[Country of Origin],SELECTEDVALUE(Table[Country of Origin])
)
One important note is that this is assuming that each Country of Origin is unique
Proud to be a Super User! | |

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I wouldn't bother nesting sentences in IFs, Switches or variables. If it's text you want to maintain / control, you could either use 'Enter data' and have a Country and Description column, or the same in an Excel file. Then on your slicer you'd have the column Country and on the card visual you'd have the description column.
If you already have the descriptions in another table, then assuming that table has a 'country' column (or any key unique key column) you could create a relationship between your country lookup table that you're using for the slicer and the key in the description table.

Helpful resources
Join our Fabric User Panel
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Power BI Monthly Update - June 2025
Check out the June 2025 Power BI update to learn about new features.

Subject | Author | Posted | |
---|---|---|---|
05-01-2025 09:21 AM | |||
12-07-2021 11:45 AM | |||
05-08-2025 12:53 AM | |||
06-09-2021 12:48 AM | |||
05-24-2025 03:56 AM |
User | Count |
---|---|
5 | |
2 | |
2 | |
1 | |
1 |