I open a new page and in IE(Using ie 11) window.opener is undefined. The window reference that window.open
returns also is full of undefined or an empty Object
.
My newly opened page needs to get the Xrm
Object from the main page, since I cannot get it otherwise and need it to do all my functionality.
Code:
function openCountyTab() {
countyTabRef = window.open("countyTab", "countyTab");
return false;
}
And in the js file of the new tab I have var opener; window.onload = function() { ... opener = window.opener; ...}
I have tried many things, including sending it to the full url, using a Blob and creating a url from that (which returns access denied), I also need to mention that when sending window.open("fullDomainName")
the Object
I get back is filled with <Access Denied>
tags.
Edit: I will state my problem more clearly. I need to open a new HTML page that is on the same domain and it needs to either get passed the Xrm
object or get it from the window that opened it. Now, the Xrm
object is needed because I use it in my script that runs on this newly opened page. Specifically, it is needed for a lib that I am using called XrmServiceToolKit
.
I use this to retrieve and modify data on a server on Microsoft's CRM Platform. I have no issue with doing any of that since everything runs fine on Chrome, FF. The problem is that the XrmServiceToolKit
cannot get the context
ie the Xrm
Object because it is null
or undefined
on the page. Therefore I cannot run my script as it depends on this. Therefore, I need a way to open a new page (not replace current window) in IE11 and give it this Xrm
object.
Hopefully that clears it up.
Any help is greatly appreciated!