unable to get property '$o_3' of undefined or null reference RRS feed

  • Question

  • Hi All,

    After the upgrade to CRM 2015 Update 1 recently, we are getting the below javascript error

    "unable to get property '$o_3' of undefined or null reference"

    for the code below

    Xrm.Page.getControl("lookupattribute").addPreSearch(function () {
         fetchXml = "<filter type='and'><condition attribute='attributename' operator='eq' value='value' /></filter>"; 


    This code worked fine before the upgrade.

    Anyone facing similar issue? Any solution?


    Wednesday, August 26, 2015 2:59 PM


  • Hi All,

    Apparently this is a bug in CRM 2015 Update 1 for Legacy forms.

    If you must use legacy forms and facing similar issue, here's the script that can resolve the issue. Add this script before calling the addPreSearch for lookup control. 

    // Attempt to force the lookup to finish initializing

            // Check if the method is available, then call it.

            Xrm.Page.getControl("lookupattribute")._control && Xrm.Page.getControl("lookupattribute")._control.tryCompleteOnDemandInitialization && Xrm.Page.getControl("lookupattribute")._control.tryCompleteOnDemandInitialization();

    Note - The above script is an internal API call thus unsupported. The way to go ahead is to use the Turbo forms as switching to Legacy forms feature will be removed in future CRM updates.



    • Marked as answer by Swaroop_d Friday, September 11, 2015 3:47 PM
    Friday, September 11, 2015 3:47 PM