| Muhammad Uzair

How to Hide or show fields in a BPF

The Business Process Flows (BPF) is one of the most valuable features in Microsoft Dynamics CRM. Initially I thought that we cannot interact with Business Process Flow fields but after some research I got to know that we can interact with BPF with javascript and here is the code which I have written to hide and show fields used in BPF:

CODE

function BPF(executionContext){

    debugger;

    var formContext = executionContext.getFormContext();

   

    var PostedToCentralDispatch = formContext.getAttribute("gs_postedtocentraldispatch").getValue();

    if(PostedToCentralDispatch == true){

        formContext.getControl("header_process_gs_postedtocentraldispatchdatetime").setVisible(true);

    }

    else{

        formContext.getControl("header_process_gs_postedtocentraldispatchdatetime").setVisible(false);

    }

}

Join us next time, as we continue our journey of learning canvas apps.Click here to learn more about Imperium's Power Apps Services. We hope this information was useful, and we look forward to sharing more insights into the Power Platform world.



About The Blog

Stay updated with what is happening in the Microsoft Business Applications world and initiatives Imperium is taking to ease digital transformation for customers.


More About Us

We provide guidance and strategic oversight to C-Suite and IT Directors for on-going implementations. Feel free to give us a call.

1 331 250 27 17
Send A Message

Ready to Start?

Get a personalized consultation for your project.

Book a Meeting