Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I have a field parameter - pretty straight forward like below.
This is on page A.
On page B, I'd like to use the same parameter, except for line "Top Countries" -
I want this to be replaced by ("Top 10 Countries SEARCH", NAMEOF('Top X'[SEARCH_TOP10_COUNTRY]), 1),
So final would look like this: If Page A, then show Version A with top countries, if page B then show verion B with Search top countries
Is there a way to do that? Or do I need to create a new parameter for each page?
So
param_gross = {
("Overall", "None", 0),
("Top 10 Countries", NAMEOF('Top X'[GROSSB_TOP10_COUNTRY]), 1),
("Company Region", NAMEOF('dim_company'[COMPANY_REGION]), 2),
("Company Country", NAMEOF('dim_company'[COMPANY_COUNTRY]), 3),
("Company Origin", NAMEOF('dim_company'[COMPANY_ORIGIN]), 4)
}
Hi @maziiw
Power BI can’t tell what page you're on, so you’ll need to set things up yourself. Add all the fields to your field parameter, then use page-level filters to control which ones show up on each page.
Hi @maziiw Field parameters are static and cannot dynamically change based on the page. To achieve this, create two separate parameters: one for Page A (with "Top 10 Countries") and one for Page B (with "Top 10 Countries SEARCH"). Use a slicer or button to detect the current page and switch parameters dynamically using a DAX measure. Alternatively, assign each parameter directly to visuals on their respective pages.
you can't directly change the definition of the parameter by page.
param_gross = { ("Overall", "None", 0), ("Top 10 Countries", NAMEOF('Top X'[GROSSB_TOP10_COUNTRY]), 1), ("Top 10 Countries SEARCH", NAMEOF('Top X'[SEARCH_TOP10_COUNTRY]), 5), ("Company Region", NAMEOF('dim_company'[COMPANY_REGION]), 2), ("Company Country", NAMEOF('dim_company'[COMPANY_COUNTRY]), 3), ("Company Origin", NAMEOF('dim_company'[COMPANY_ORIGIN]), 4) }
On Page A, filter out "Top 10 Countries SEARCH" in your slicer or set a default.
On Page B, filter out "Top 10 Countries" and default to the SEARCH version.
Or, if you don’t want users to choose at all, use DAX to dynamically control the field in your measure or visual:
SelectedField = SWITCH( TRUE(), SELECTEDVALUE('Page Filter'[Page]) = "A" && SELECTEDVALUE('param_gross'[param_gross_order]) = 1, SELECTEDVALUE('Top X'[GROSSB_TOP10_COUNTRY]), SELECTEDVALUE('Page Filter'[Page]) = "B" && SELECTEDVALUE('param_gross'[param_gross_order]) = 5, SELECTEDVALUE('Top X'[SEARCH_TOP10_COUNTRY]), -- Add other mappings as needed BLANK() )
And use this SelectedField in your visuals instead of directly using the parameter.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
78 | |
77 | |
59 | |
36 | |
33 |
User | Count |
---|---|
100 | |
62 | |
56 | |
47 | |
41 |