Skip to main content

Notifications

Dynamics 365 Community / Forums / Finance forum / Disabling and enabling...
Finance forum
Suggested answer

Disabling and enabling the button based on workflow approval

editSubscribe (2) ShareShare
ReportReport
Posted on by 7
I had created the custom workflow for Bank account reconcilation but now I want to disable the Reconcile account button and need to enable it after workflow approval 
 
  • Suggested answer
    Mohamed Amine Mahmoudi Profile Picture
    Mohamed Amine Mahmoudi 4,249 User Group Leader on at
    Disabling and enabling the button based on workflow approval
    Hi,
     
    Surely there's a status to indicate the state of the WF (Approved, Rejected ...).
    As Martin and Baharani said, you can apply the Active() method.
     
    Mohamed Amine MAHMOUDI
  • Suggested answer
    Bharani Preetham Peraka Profile Picture
    Bharani Preetham Pe... 3,495 Super User on at
    Disabling and enabling the button based on workflow approval
    You can add this check that if workflow is approved then only enable the reconcile button in the form data source level active method post next().
  • Martin Dráb Profile Picture
    Martin Dráb 223,212 Super User on at
    Disabling and enabling the button based on workflow approval
    The state of the document must be stored in a field. Then you'll simply check whether the status is Approved and enable or disable the button. That's normally done in active() method, but don't forget to check whether the form doesn't already contain another piece of logic enabling the button. If so, you'd need to take that into account.
     
    (Moved from D365 general forum.)

Helpful resources

Quick Links

Take the Community feedback survey!

Answer this brief 15-question survey about your Community experience…

Demystifying Copilot: Service Edition with Sundar Raghavan

Sundar answers more questions about Copilot for Service...

Dynamics 365 Business Central vs Finance and SCM

Take a look at the key differences between Business Central and…

Leaderboard

#1
Andre Arnaud de Calavon Profile Picture

Andre Arnaud de Cal... 283,373 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 223,212 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,140

Featured topics

Product updates

Dynamics 365 release plans