Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :

Decrypting CRM JavaScript Runtime Errors

Mitch Milam Profile Picture Mitch Milam

If you have spent any time at all writing JavaScript for CRM you have probably made at least one programming error that has resulted in your page failing to work properly.

CRM will display the following in the bottom-left corner of your page:

image

Not very helpful, and sometimes not very noticeable either. However, when you close the window CRM will display the following dialog:

image

Now we’re getting somewhere.  This is CRM’s built-in error collection tool that the CRM development team uses to record and track errors within CRM.  The data is scrubbed of anything that resembles personal or proprietary information then sends the data ( as long as you click Send Error Report ) to a collection server at one of Microsoft’s Internet sites.

But, this information can also be helpful to you, since you caused the error.

If you click the middle link, View the data that will be sent to Microsoft you will see the actual JavaScript error that cause the error on the page:

 image

Well that is all great, good, and wonderful, but what does it mean?  Expected what???

You have two options:

1) You can hunt down an Internet that has a character table that lists characters and their numeric value; or:

2) You can turn to Google.  Simply paste the message into the search box of Internet Explorer ( the top box ), press Enter, and the results will be shown in your default language on the Google search page:

image

Alas, Bing Search does not seem to offer the same capability.

 

So there you have it.  Hopefully this will help the next time you accidentally introduce an error into your code.

As a final note, sometimes the information shown in the error message dialog is of no use to you at all.  You will see something like, an error occurred on line 743, character 15.  Since CRM wraps your code within their code, this type of information is less than useful to you so you may spend more than a little time tracing down your exact problem.

Special thanks to Daniel Cox who showed me the Google trick.


This was originally posted here.

Comments

*This post is locked for comments