D365 Common Functions - Jump Start Development

function SetFormContextToTheWebResource(formContext, htmlResources) {
   // debugger;
    for (var i = 0; i < htmlResources.length; i++) {
        var wrControl = formContext.getControl(htmlResources[i]);
        if (wrControl) {
            wrControl.getContentWindow().then(
                function (contentWindow) {
                   // debugger;
                    contentWindow.setFormContext(formContext, Xrm);
                }
            );
        }
    }
}

Comments

Popular posts from this blog

Dynamics 365 - Dynamically create Custom Lookup View(JavaScript)

Dynamics 365 - Xrm WebAPI

Microsoft Portal JavaScript