GridView and EnableHeaderCheckBox

5 posts, 0 answers
  1. Deepak
    Deepak avatar
    27 posts
    Member since:
    May 2016

    Posted 28 Jun 2017 Link to this post

    Hello,

    I created GridView with dataset and added two CheckBox type column. In telerik documenation, there is one method to add checkbox on Header

    GridViewCheckBoxColumn includeColumn_ = new GridViewCheckBoxColumn();
               includeColumn_.DataType = typeof(int);
               includeColumn_.EnableHeaderCheckBox = true;
     
               GridViewCheckBoxColumn excludeColumn_ = new GridViewCheckBoxColumn();
               excludeColumn_.DataType = typeof(int);
             //  excludeColumn_.EnableHeaderCheckBox = true;

     

  2. Deepak
    Deepak avatar
    27 posts
    Member since:
    May 2016

    Posted 28 Jun 2017 Link to this post

    First post is not complete. Please ignore it. Apologies. 

    I created GridView with dataset and added two CheckBox type column. In telerik documenation, there is a method to add checkbox on Headers of a grid.

    1.GridViewCheckBoxColumn includeColumn_ = new GridViewCheckBoxColumn();
    2.includeColumn_.DataType = typeof(int);
    3.includeColumn_.EnableHeaderCheckBox = true;
    4. 
    5.GridViewCheckBoxColumn excludeColumn_ = new GridViewCheckBoxColumn();
    6.excludeColumn_.DataType = typeof(int);
    7.excludeColumn_.EnableHeaderCheckBox = true;

     

    Now when i use this code i get an error(See attached file). It seems like i cannot use two HeaderCheckbox at a same time. 

     

    Is this possible ?

     

    Thanks and Regards,

    Deepak

  3. Dimitar
    Admin
    Dimitar avatar
    2841 posts

    Posted 28 Jun 2017 Link to this post

    Hello Deepak,

    It is possible to use more than one checkbox column with enabled header checkbox. The reason for the exception is somewhere else. Could you please share the entire code used for binding the grid and adding the columns?

    I am looking forward to your reply.

    Regards,
    Dimitar
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  4. Deepak
    Deepak avatar
    27 posts
    Member since:
    May 2016

    Posted 29 Jun 2017 in reply to Dimitar Link to this post

    Hello Dimitar,

    I have already shared the piece of code I have used and exception it throws.

     

    Regards,

    Deepak

  5. Dimitar
    Admin
    Dimitar avatar
    2841 posts

    Posted 29 Jun 2017 Link to this post

    Hi Deepak,

    I already tested this but there is no exception on my side (see attached video). This is why I have asked you for the rest of the code.

    I am looking forward to your reply. 

    Regards,
    Dimitar
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top