CRM 2011: Javascript, retrieving data from parent entity RRS feed

  • Question

  • I have a entity called Household, which holds the info of two people: Client A and Client B. When I create a new Contact from within this entity, I want to auto populate some fields based on a picklist within Contact that contains the options Client A and B. Normally I would do this through relationship mapping and workflows, but in this case I'm unable to map both a Client A and Client B field from Household, to a singular field in Contact.

    So I'm using window.top.opener.parent.Xrm.Page to access the parent form Household, and putting this in the onChange event in the picklist. I've tested this, and this code so far works; the parent page exists.


    However, when I try window.top.opener.parent.Xrm.Page.getAttribute(<name>).getValue() I get an error that says "Error:Object doesn't support this property or method." Is this a bug in CRM 2011? I've tested similar code in CRM 4.0 and it works as intended.

    Wednesday, April 13, 2011 4:05 PM


All replies