Showing results for 
Search instead for 
Did you mean: 
New Member

Disabling model driven app button on form



I have created a button command in Model driven app (on a Microsoft dynamics CRM Form)

Is there a way to disable the button after clicking it once using some kind of timers?

Helper V
Helper V

@janvi_1 You cant hide it based on timer. You can write JS and hide the button based on any field value. Haven't tried Power FX but you should be able to do.

Super User
Super User

Hi @janvi_1 , 


Not a timer, but you could use some javascript: 

Use a variable (like isClicked=false). After a click, set it to true. You could use that variable in an enableRule script.

When the "icClicked" gets changed from false to true, you can call refreshRibbon, so the enable Rule gets applied.


If the purpose of your question, is to avoid having parallel running scripts (so if you intend to enable the button again when an operation finished), I would suggest to treat that inside the code, and let the button enabled all the time. Maybe you could show a notification as a feedback to the user.

Kind regards,
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Helpful resources

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Power Apps Ideas

Check out the New Ideas Site

We are excited to announce a new way to share your ideas for Power Apps!

Top Solution Authors
Top Kudoed Authors
Users online (3,350)