Unterminated string constant on Line 49

Posted on 2012-08-16
Last Modified: 2012-08-17
Hello Experts,

I need some help with the attached script which is an OnLoad event on the quote entity.

I am trying to get the ChangeInspectionSite function to work as an OnChange event of the customerid field. I am getting the following error when the form loads. I hope you can help. I have been given a deadline of next Wednesday to have everything fixed and I do not have Visual Studio to help with the debugging.

= = = = = = =

The popup alert is:

     There was an error with this field's customized event.

     Error: The value of the property 'PopulateBillToInformation' is null or undefined, not a Function object.

= = = = = = = = = =
Microsoft Dynamics CRM Error Report Contents

   <Message>Unterminated string constant</Message>
   <BrowserUserAgent>Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/5.0; SLCC2; .NET CLR 2.0.50727; Media Center PC 6.0; .NET CLR 3.5.30729; .NET CLR 3.0.30729; InfoPath.3; MS-RTC EA 2; .NET4.0C; .NET4.0E; .NET CLR 1.1.4322; MS-RTC LM 8; Microsoft Outlook 14.0.6117)</BrowserUserAgent>
   <ClientName>Outlook Laptop - Online</ClientName>
Question by:jlblanke
    LVL 27

    Expert Comment

    by:Chinmay Patel
    Hi Jblanke,

    I suggested to use few IDEs available online did you try using any of them?

    LVL 27

    Accepted Solution

    Hi jblanke,

    Line 49 and 50, you have entered a blank line, which is not allowed when you are building SOAP calls.

    request += "<Execute xmlns=\"\" xmlns:i=

    Open in new window


    Author Closing Comment

    Thanks for helping me! The example was exactly what I needed to locate the problems.

    I was able to get the script to load successfully. It is hard for me to find many of these typos without Visual Studio. Also, I think the copy/paste between Notepad and CRM is causing some additional line breaks to occur.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Threat Intelligence Starter Resources

    Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

    On Sep 22nd 2014 Microsoft released Update Rollup 1 for Microsoft Dynamics CRM 2013 Service Pack 1 and back in July Update Rollup 3 was released.  So we now have:   Update Rollup 1Update Rollup 2Update Rollup 3Service Pack 1Update Rollup 1 for S…
    Automatically creating a Trello card using data from a Microsoft Dynamics CRM record turned out to be an easy project that yielded great results.  Here's how I did this for an internal team at General Code.
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now