web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

ReferenceError: functionSample is not defined at eval (eval at RunHandlerInternal when i reload the page

(0) ShareShare
ReportReport
Posted on by 215

Hi guys,

I'm facing a rather interesting problem. 

When i go to my lead form i have a sub-grid and a button on the top ribbon for adding new products through the Quick Create Form and they work fine as long as i do not refresh the page.

Oddly enough if I navigate to let's say the Contacts or any other record and then come back to my lead and i press the buttons to open the Quick Create Form for my custom entity Product they work just fine.

But if i get to my leads form and then reload the page i get the Reference Error that my function has not been defined at eval.

Any suggestions are welcomed.

*This post is locked for comments

I have the same question (0)
  • Filip Vanchevski Profile Picture
    215 on at
    RE: ReferenceError: functionSample is not defined at eval (eval at RunHandlerInternal when i reload the page

    I would like to point out that both the script/library and the function itself are registered on the Quick Create Form of the custom entity Product, the function is registered under Form on the OnLoad event (it simply hides some fields that we do not want to show if anyone wants to create a product from the Lead entity)

  • Sanjaya Yapa Profile Picture
    15 on at
    RE: ReferenceError: functionSample is not defined at eval (eval at RunHandlerInternal when i reload the page

    Hi Fillip

    If you are referring to the following error, then there is no straight forward answer for it. I was also facing the same and tried to so many things.

    5810.ScriptError.PNG

    Some sources say it is a caching error, so I suggest you check that first or open in a new browser. If still the problem pops up, then check your javascript wiring with CRM. In my case, there was a typo on function name. When I corrected it the problem disappeared. 

    I would be happy to assist you with your code to spot any issues if you don't mind sharing it with me.

    Thanks

    Sanjaya

  • Filip Vanchevski Profile Picture
    215 on at
    RE: ReferenceError: functionSample is not defined at eval (eval at RunHandlerInternal when i reload the page

    Hi Sanjaya,

    It turns in my case at least that this was caused by an error above the definition of the function at which point the script stops execution and the function does not get loaded in CRM, after that when the trigger for the function happens the function is not defined and we get the error.

    Hopefully it will be of help to someone else :)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
HR-09070029-0 Profile Picture

HR-09070029-0 2

#1
UllrSki Profile Picture

UllrSki 2

#3
ED-30091530-0 Profile Picture

ED-30091530-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans