Use JavaScript in Dynamics CRM to Set the Value in Read-Only Field on a Form

By default CRM will not allow you save the data assigned to readonly field. For that we have use below javascript code snippet to make this work.

For ex new_amount is the readonly field in your form. So to save the data assigned to it use the below code snippet

function SetSubmitForAmountField()
{
Xrm.Page.getAttribute("new_amount").setSubmitMode("always");
}


You have to call this function on onsave of your form as shown below.

Featured Post

Improving MS CRM Performance

Performance on MS CRM is always a crucial thing and we may follow different ways to achieve the performance thing. Below is the one more a...