Issues with dropdownlist in IE

3 posts, 0 answers
  1. Saju Samuel
    Saju  Samuel avatar
    15 posts
    Member since:
    Jul 2009

    Posted 27 May 2014 Link to this post

    Hi Telerik team:

    I'm currently using DropDownList with checkboxes on javascript and I found out that method get_checked, that retrieves wether an item is checked or not
    does not work on IE.
    Exists some fix to use this method on IE? 

    Any help would be appreciated.
    Thanks.


    function doSaveReport(id) {

                if ($("#txtSaveAs").val() == "" && id == "")
                    alert("You must specify a name for the report definition");
                else {
                
                          oEmployee = $find("<%= ddlEmployees.ClientID %>").get_items(),
                            
                    var ReportData = {                  
                        EmployeeId: []
                    }   
               
                    for (i = 0; i < oEmployee.get_count(); i++) {
                        item = oEmployee.getItem(i);
                        if (item.get_checked())
                            ReportData.EmployeeId.push(item.get_value());
                    }
    }

























  2. Saju Samuel
    Saju  Samuel avatar
    15 posts
    Member since:
    Jul 2009

    Posted 27 May 2014 in reply to Saju Samuel Link to this post

    I forgot to add the dropdown html code...

      <telerik:RadComboBox ID="ddlEmployees" runat="server" EnableCheckAllItemsCheckBox="true" 
                       CheckBoxes="true"  Width="250px"></telerik:RadComboBox>
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 28 May 2014 in reply to Saju Samuel Link to this post

    Hi Saju Samuel,

    Please do the following modification in your  JavaScript which works fine at my end.

    JavaScript:
    function doSaveReport() {
        var oEmployee = $find("<%= ddlEmployees.ClientID %>").get_items();
        for (var i = 0; i < oEmployee.get_count(); i++) {
            if (oEmployee.getItem(i).get_checked()) {
              //your code
          }
        }
    }

    Thanks,
    Shinu.
Back to Top