CRM 2013 – Business Process Flow – Disable the fields on process bar

Dynamics CRM 2013 BPFs have many beneficial qualities.  They are available for both OOB and custom entities, can span across multiple entities.

When a form displays a business process flow control in the header, additional controls will be added for each attribute that is displayed in the business process flow. These controls have a unique name like the following: header_process_<attribute name>.

Controls displayed in the form header are accessible and have a unique name like the following: header_<attribute name>.

CRM Process bar

CRM Process bar

We have requirement to disable the fields on process bar based on some logic. Below is the Java Script code to implement it:

var c = Xrm.Page.getControl(“header_process_xxxxxxxx”);  //Get the field from process bar

if (c!= null) {

c.setDisabled(true);

}

CRM Process bar

CRM Process bar

 

I hope you find it useful!

Author: Zhe Chen
Title: Lead Dynamics CRM Consultant @ Adisys
Email: zhechen@adisys.co

One thought on “CRM 2013 – Business Process Flow – Disable the fields on process bar

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s