Broken Javascript

3 posts, 0 answers
  1. Alex
    Alex avatar
    77 posts
    Member since:
    Mar 2008

    Posted 11 Feb 2015 Link to this post

    I have a in-house web-app that has been in production for 3 years. We have been using an old version of IE (9 to be precise).

    We are testing IE11 now and I have this weird issue.

    On some of my Telerik controls I have client-side events, ex.: on a radComboBox I have <I>onclientselectedindexchanged</I> and an associated event (function).

    In IE11 I get the following error "JavaScript runtime error: 'rcbMarketTypeIndexChanged' is undefined", but in IE9, current versions of Firefox and Chrome I do not get any such errors and the functionality related to 'rcbMarketTypeIndexChanged' executes fine.

    The javascript is embedded in the aspx file with the proper <scripts> tags.

    I'm assuming that it might be related to a javacript syntax error (that I cannot find) which is rearing it's ugly head but I would assume it would affect other browsers including IE9 if that was the case.

    Any suggestions on how to pin-point and rule out a javascript syntax issue.


  2. Marin Bratanov
    Marin Bratanov avatar
    3558 posts

    Posted 13 Feb 2015 Link to this post

    Hi Alex,

    It is possible that IE11 is now in compatibility mode, and treats scripts as it if were IE7, so it is possible that a coma at the end of a JSON literal breaks your scripts. This is, of course, just a guess at this point.

    What I can suggest is the following:

    If this does not help you find and correct the error, it should leave you with a sample you can send us so we can review it.


    Marin Bratanov

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

  3. DevCraft R3 2016 release webinar banner
  4. Alex
    Alex avatar
    77 posts
    Member since:
    Mar 2008

    Posted 27 Feb 2015 in reply to Marin Bratanov Link to this post

    Finally figured out the situation.

    All of my javascript, including radscriptblocks are at the end of my HTML to help load performance on slow connections.

    Moving the javascript to the top of the content page solved this problem.

    I did some testing and only telerik controls had problems with javascript being at the bottom of the page in IE11, html controls that called javascript didn't care where the javascript was.

Back to Top