Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join 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.

Reply
tomas12344
Helper III
Helper III

enable/disable dynamically button

A customer need a page/report, where some buttons will be dynamically enabled/disabled based on logged user (the identification of the logged user I have done, question is only abou the dynamic enabling/disabling). Button should contian some URL link to some page, so when user is alowed use the button, it will open the page. When the user is not allowed, the button should be somehow disabled/grey out. 

 

Buton should have some icon on it, some text, fill, shape... The icon and collor, fill of the button should dynamic also change based on the user (the color change and fill is done).

 

I think, I should use for this the button visual, not shape, image... As the button has more states (on hover, ....) which in this case is a wanted feature. 

 

The question is, or I dont know how to do:

1 generaly I would like to use all the state, that are available to the button visual. The Defaul, on hover and on press I use, but dont know how the get the disable state to change some color,... of the button. 

2 dynamically enable/disable the button. I found, that when the button is used for navigation on pages, the button can be disabled, when there is empty or non-valid page name/refrerence. Is there a way to dynamically enable/disable button, when the button is used for web URL link? I tried to put there empty URL, or something like that, but the button did not went to disabled statet. (currently I change with a measure the background color of the button, when the user is not alowed to use the button, this is not very optimal)

3 aditionaly to the previous point, is there a way to dynamicaly change the icon, that is assigned to the button? This would be nice, when in disabled state, the icon would be only B&W, insted of when in enabled state the icon will be color. 

 

Any idea how to do?

8 REPLIES 8
v-vpabbu
Community Support
Community Support

Hi @tomas12344,

 

As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.

 

Regards,
Vinay Pabbu

Hi @tomas12344,

 

As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.

 

Regards,
Vinay Pabbu

Hi @tomas12344,

 

As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.

 

Regards,
Vinay Pabbu

v-vpabbu
Community Support
Community Support

Hi @tomas12344,

 

It is not fully possible in Power BI to dynamically disable a button (used for a web URL) with proper disabled-state visuals like greyed-out color, icon change, or preventing clicks.

the only workaround i can suggest is Use visibility toggles + blank URL + formatting to fake the disabled behavior.

 

Regards,

Vinay

Akash_Varuna
Community Champion
Community Champion

Hi @tomas12344 I think you could try using a measure and conditional formating could you try these please 

  • Use measures to control button properties, such as dynamically assigning an invalid or empty URL to unauthorized users, preventing navigation.
  • Change button visuals, such as color or text, using conditional formatting based on measures to indicate disabled states.
  • Simulate icon changes by using measures to dynamically swap icons or adjust their colors.
    If this post helped please do give a kudos and accept this as a solution
    Thanks In Advance

hi @Akash_Varuna 
Can you show me how to use a measure to define the icon? I cannot find it. Of course for a button. not for anything else.
Can you tel me how is an invalid URL defined for PBI?

Anonymous
Not applicable

hi @Anonymous 

no this is not, what I need. As you know, there is the disable state for the button and I need to use that state.

Helpful resources

Announcements
Join our Fabric User Panel

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.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.