Javascript error on postback

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

    Posted 04 Nov 2010 Link to this post

    I don't know I just feel that I get the weirdest errors.

    I have a simple set-up, I have a radgrid with a MasterTableView and a DetailTableView.

    In the DetailTableView I have radComboBoxes and the combo boxes are all set to AutoPostback="true" so when the selectedindexchanges the autopostback fires. To minimize the possibilities I even removed the code from the code behind and just kept the Sub, so at the moment it postbacks to an empty Sub.

    When it fires I get a javascript error in Sys$WebForms$PageRequestManager$_endPostBack indicating a server error (500).

    For testing purposes I put some radComboBoxes on the MasterTableView and put some code for the postback and I do not get a javascript error.

    Thanks
  2. Alex
    Alex avatar
    77 posts
    Member since:
    Mar 2008

    Posted 04 Nov 2010 Link to this post

    OK after digging I've found the issue.

    All radComboBoxes are populated via a datasourse but all have 1 default item in them and that is <Select> so the user knows that's something needs to be selected.

    When I use the radCombobox Item Builder to do the create the <Select> item, the code generated is:

     

     

    <telerik:RadComboBoxItem runat="server" Text="&lt;Select&gt;" Value="0" />

     


    This for whatever reason causes the Javascript error, if I go and change it for the following:

    <

     

     

    telerik:RadComboBoxItem runat="server" Text="<Select>" Value="0" />

     


    Everything runs GREAT.

    Only took me 3 hours to pin it down.
Back to Top