I have an entity form
I added a jscript file as a web resource
I am able to add css files to head of the document and other stuff using the javascript
But when I try using XRM, it throws
VM11662:1 Uncaught ReferenceError: XRM is not defined
function load_css_file(filename){
var fileref = document.createElement("link")
fileref.setAttribute("rel", "stylesheet")
fileref.setAttribute("type", "text/css")
fileref.setAttribute("href", filename)
document.getElementsByTagName("head")[0].appendChild(fileref)
}
function onFormLoad(){
load_css_file('/WebResources/new_Style.css');
var something = Xrm.Page.ui.tabs.get("sometabname").sections.get("some name");
};
*This post is locked for comments
I have the same question (0)