checkbox in header cell of a checkbox column

10 posts, 0 answers
  1. Shashiram
    Shashiram avatar
    5 posts
    Member since:
    Jun 2010

    Posted 24 Aug 2010 Link to this post

    Hi,
    we have check box in header cell of acheck box column and it is working fine for the version (2009.3.9.1203)
    when we upgrade the dlls to new version (2010.2.10.713) its not working.

    /// Class to Display check box Header cell
        public class CheckBoxHeaderCell : GridHeaderCellElement
        {
        }
    I am getting some problem in the above class.

    please give the work around for the new dlls.

    Thank you,
    Shashi


  2. Alexander
    Admin
    Alexander avatar
    306 posts

    Posted 26 Aug 2010 Link to this post

    Hello Shashiram,

    Thank you for your question.

    The Knowledge base article for the header cell check box is updated and compatible with Q2 2010 SP1 (v2010.2.10.806) version of the RadGridView control. Please review the updated article here.

    I hope it helps.

    Regards,
    Alexander
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Greg
    Greg avatar
    1 posts
    Member since:
    Jun 2010

    Posted 27 Oct 2010 Link to this post

    Hi Alexander, I'm trying to figure out how to put a link label into the header of a RadGridView. I'm thinking that the check box in header article is what I need to read but sadly that link you've put in does not go to a valid article. Has the article moved?

    Cheers
    Greg
  5. Emanuel Varga
    Emanuel Varga avatar
    1336 posts
    Member since:
    May 2010

    Posted 27 Oct 2010 Link to this post

    Hello Greg,

    Here is the updated link for the Select all checkbox in header KB Article.

    Hope this helps, if you have any other questions or comments, please let me know,

    Best Regards,
    Emanuel Varga
  6. Tim
    Tim avatar
    8 posts
    Member since:
    Jul 2014

    Posted 04 Dec 2014 in reply to Alexander Link to this post

    Hello Alexander,

    I can create a GridViewCheckBoxColumn, but I can't find EnableHeaderCheckBox property. Finally, I have to place a checkbox control in the column header cell. What's the problem? I used theTelerik UI for WinForms Q2 2014. 

    Thank you in advance.
  7. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 05 Dec 2014 Link to this post

    Hello Tim,

    The check box in the header was introduced in Q2 2014 SP1. Here is the blog announcement: http://blogs.telerik.com/winformsteam/posts/14-09-19/search-for-data-and-batch-change-booleans-in-radgridview-for-winforms-like-never-before.

    For previous versions you can use the approach suggested in this KB article: http://www.telerik.com/support/kb/winforms/gridview/details/add-check-all-in-the-header-cell-for-a-gridviewcheckboxcolumn.

    I hope this helps.

    Regards,
    Stefan
    Telerik
     

    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.

     
  8. Tim
    Tim avatar
    8 posts
    Member since:
    Jul 2014

    Posted 04 Jan 2015 Link to this post

    Hello Stefan,

    I have red the blog announcement and do it in many ways, but it still doesn't work. Here is my code in Form_load():

    GridViewCheckBoxColumn checkBoxColumn = new GridViewCheckBoxColumn();
    checkBoxColumn.DataType = typeof(int);
    checkBoxColumn.Name = "checkboxColumn";
    checkBoxColumn.FieldName = "checkbox";
    checkBoxColumn.HeaderText = "OK?"; 
    radGridView1.Columns.Add(checkBoxColumn); 
      
    I can't find the "EnableHeaderCheckBox" property, Please do me a favour.

    Best Regards,
     
































































































































  9. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 05 Jan 2015 Link to this post

    Hello Tim,

    The only reason why you would not find this property is if you are using a version where this functionality was not introduced. The check box in the header was introduced in Q2 2014 SP1. If you still experience issues, please open a new support ticket and attach your project in it, so we can investigate it.

    Regards,
    Stefan
    Telerik
     

    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.

     
  10. Tim
    Tim avatar
    8 posts
    Member since:
    Jul 2014

    Posted 12 Jan 2015 Link to this post

    Hi,

    I add a checkbox in the header of GridViewCheckBoxColumn by the EnableHeaderCheckBox property. Next, I want to set the CheckState to true for the header checkbox, My code is as follows,

    private void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
    {            
          if (e.CellElement is GridCheckBoxHeaderCellElement)
          {
                for (int i = 0; i < e.CellElement.Children.Count; i++)
                {
                      if (e.CellElement.Children[i] is RadCheckBoxElement)
                      {
                           (e.CellElement.Children[i] as RadCheckBoxElement).Checked = true;
                      }
                }
          }            
    }   

    But ArgumentOutOfRangeException is happened, so please help me figure out what's the problem.
    Another question, how to align the checkbox in the header of GridViewCheckBoxColumn?

    Best Regards,

  11. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 12 Jan 2015 Link to this post

    Hi Tim,

    You can use the GridViewCheckBoxColumn's Checked property to check the header check box.

    I hope that you find this information useful. Should you have any other questions, do not hesitate to contact us.

    Regards,
    Stefan
    Telerik
     

    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.

     
Back to Top
UI for WinForms is Visual Studio 2017 Ready