Error OnSave Get Object CRM 2011

Hi all,

 

I’m new to the forum and CRM so hoping you experts can help solve a minor irritation J

 

Recently we’ve started to get an error message when we click on ‘Save’ or ‘Save & Close’ in Opportunity records.

 

“There was an error with this field's customised event.

 

Field:crmForm

 

Event:onsave

 

Error:Unable to get property 'getObject' of undefined or null reference”

 

We're not 100% what triggered this as we have done a few changes to the Opportunity form, moved, added and removed superfluous fields, so could be anyone of these.

 

The script in question is:

 

//call the saveMultiSelect function of the Multiselect html web resource on save of the form.

 

function multiSelectOnSave(executionObject) {

 

   Xrm.Page.getControl(executionObject).getObject().contentWindow.window.saveMultiSelect();

 

}

 

I’ve searched high and low to try and solve this question, looked in books and scoured the internet but without success, what I need to know is:

 

a)      Is it safe to just delete this event?

b)      If not can anyone help or point me in the right direction to correct it?

 

Any help would be greatly appreciated.

 

Many thanks

 

 

 

Nick

  • Hello Nick,

    Most likely you removed some fields from form. I guess you can disable this function, since field that was used in it no longer used.

  • In reply to Roman Rudenko:

    Hi Roman,

    I finally deleted it and it all seems OK so many thanks for your reply.

     

    Kind regards

     

     

     

    Nick

Related
Recommended