CheckBox in CellTemplate gets unchecked on scrolling

10 posts, 0 answers
  1. Ramya
    Ramya avatar
    27 posts
    Member since:
    Jan 2011

    Posted 27 Aug 2011 Link to this post

    Hi,
    I have a GridViewDataColumn and I have put a checkbox in its CellTemplate. The problem is that when I check this checkbox and scroll down, the checBox gets unchecked. Though the uncheck event is not fired, it looks unchecked. I have not applied any style to the checkbox. What can be the reason? How can I fix this.
    Thanks,
    Ramya
  2. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 29 Aug 2011 Link to this post

    Hi Ramya,

    This behavior may be caused in the case the IsChecked property of the CheckBox is not bound. May you post some more information about the definition of the column ?
     

    Kind regards,
    Maya
    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

  3. DevCraft banner
  4. Mario Priebe
    Mario Priebe avatar
    3 posts
    Member since:
    Sep 2012

    Posted 19 Sep 2011 Link to this post

    We have also this problem. The checkbox elements are bound:

    <telerik:GridViewDataColumn DataMemberBinding="{Binding Exkl}">
        <telerik:GridViewDataColumn.Header>
            <TextBlock Text="ausschl." />
        </telerik:GridViewDataColumn.Header>
        <telerik:GridViewDataColumn.CellTemplate>
            <DataTemplate>
                <CheckBox IsChecked="{Binding Exkl}" HorizontalAlignment="Center" />
            </DataTemplate>
        </telerik:GridViewDataColumn.CellTemplate>
    </telerik:GridViewDataColumn>

    If I scroll the grid, loosed the checkbox the state and the grid select any other checkbox.
  5. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 19 Sep 2011 Link to this post

    Hello Mario,

    I have tried to reproduce the issue, but still without any success. May you take a look at the sample attached to verify whether I am testing it correctly ? Can you get the same behavior on this project ?

    Regards,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  6. Mario Priebe
    Mario Priebe avatar
    3 posts
    Member since:
    Sep 2012

    Posted 19 Sep 2011 Link to this post

    Thanks for your fast reply.
     
    Your example works fine. But the same code in my solution still give the issue.
    Our hierarchy look like:
     
    controls:ChildWindow
        telerik:RadTabControl
            telerik:RadTabItem

    the grid has follow attributes

    <telerik:RadGridView ShowGroupPanel="False" telerik:StyleManager.Theme="Transparent"
     ItemsSource="{Binding Source={StaticResource ourSource}}" SelectionMode="Multiple" AutoGenerateColumns="False">

    I dont know, what seems the difference.
  7. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 19 Sep 2011 Link to this post

    Hi Mario,

    Even after changing the project so that it uses the structure you mentioned, I am not able to reproduce the issue. I am attaching the updated sample. May you take a look and try to reproduce the behavior on this application ? 

    All the best,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  8. Kevin
    Kevin avatar
    2 posts
    Member since:
    Oct 2011

    Posted 20 Oct 2011 Link to this post

    We are having a similair issue in Winforms.  As we scroll around our grid, we see green-checked checkboxes (which are properly checked) AND black-checked ones that seemingly randomly check and uncheck themselves as we scroll up and down.  Any ideas?
    Kevin D
  9. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 21 Oct 2011 Link to this post

    Hi Kevin,

    This forum targets only RadControls for Silverlight. I will encourage you to post your question on the appropriate forum for WinForms.
    Thank you for your understanding.

     

    Kind regards,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  10. Abílio
    Abílio avatar
    6 posts
    Member since:
    Sep 2011

    Posted 21 Mar 2013 Link to this post

    HI there.

    We´re catching the same problem. Didi anyone find the solution or the reason for this problem to happen?

    Thanks in advanced.
  11. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 21 Mar 2013 Link to this post

    Hello Abilio,

    Will it be possible to clarify which controls you work with - for WPF or WinForms ? If it is the first case, could you reproduce the behavior in the sample attached ? 

    Kind regards,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top
DevCraft banner