Tag Archives: Parent Form

Accessing the Parent Form Xrm.Page in CRM 2011

For those of you trying to access a parent form’s Xrm.Page object in CRM 2011 you can use the following syntax.

From an IFrame HTML page


From a new window/dialog


An example of a new window being used is when you are viewing the Account Form and then choose to create a new Contact from the left hand navigation pane and then within the Contact Form you need to access the Account Form (parent).

Potential CRM 4 syntax to be replaced is as follows


If you have downloaded the CRM 4 to CRM 2011 JavaScript Converter Tool before December 2010 then you can add the following code snippets to the TOP of the ConversionList.xml file straight after the <snippets> node, alternatively just download the tool again.


Both Mitch Milam MVP and I searched high and low for this solution as the Xrm.Page object is not in the DOM at that same location as the CRM 4 crmForm object. Please let us know if you experience any problems with accessing parent forms and we will try and help you.

Also if you liked my CRM 4 to CRM 2011 JavaScript Converter Tool then you might like to take a look at Mitch Milam’s CRM Migration Assistant also for converting scripts.

From IE Developer Tools

Also, Paul Way has shown that you can access the Xrm.Page object from the Developer Tools console window using the following code.