Refresh a Web Resource in Dynamics CRM 2015
Use the following function to refresh the Web Resource on your form. Just remember to pass the parameter for your Web Resource Name. function refreshWebResource(myWebResourceName) { //get and validate current id var currentId = Xrm.Page.data.entity.getId(); if (currentId != null && currentId != undefined && currentId != "") { //get and set the querystring from the control var querystring = Xrm.Page.getControl(myWebResourceName).getSrc(); Xrm.Page.getControl(myWebResourceName).setSrc(querystring + "&data=" + currentId); } }