This is a migrated thread and some comments may be shown as answers.

[Solved] All rows appear selected when first loaded

3 Answers 76 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Glenn
Top achievements
Rank 1
Glenn asked on 10 Jan 2011, 03:17 PM
I have a GridView that is bound to a ModelView property that is an ObservableCollection of a fairly simple business object.  However, when the binding occurs, it appears that all the rows are selected.  I have other similar GridViews in my application that work perfectly well.  I am not sure why this does not display properly.

Below is the GridView definition:

<telerik:RadGridView x:Name="radGridView" 
     CanUserFreezeColumns="False" 
     AutoGenerateColumns="False" 
     IsReadOnly="True" 
     ShowGroupPanel="False"
     Height="287" 
     ItemsSource="{Binding Path=UserItems}">
    <telerik:RadGridView.Columns>
       <telerik:GridViewDataColumn Header="Name" 
            DataMemberBinding="{Binding UserName}" 
             IsGroupable="False" 
             IsFilterable="False" />
                 <telerik:GridViewDataColumn Width="*" 
                           Header="Address" 
                           DataMemberBinding="{Binding Email}" 
                           IsSortable="False" 
                           IsFilterable="False"/>
                 </telerik:RadGridView.Columns>
            </telerik:RadGridView>

I've also attached a screen-shot of what the gridView looks like.
Can anyone provide any insight into what would cause the GridView to behave like this?
Thanks,
Glenn


3 Answers, 1 is accepted

Sort by
0
Vanya Pavlova
Telerik team
answered on 10 Jan 2011, 03:45 PM
Hi Glenn,

 
Thank you for sharing with is this picture and code-snippet, however we are not able to reproduce this issue by our side. Can you please share with us a little bit more info about the grid version you used? It could be great if you can send us a small application via support ticket which we can debug manually.
Thank you!
 

Best wishes,
Vanya Pavlova
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Glenn
Top achievements
Rank 1
answered on 10 Jan 2011, 04:44 PM
Hi Vanya:

I noticed that I was not using the latest Telerik libraries so I upgraded to version 2010.3.1110.1040.  Although, the GridView displays slightly different, I am still experiencing the same issue.

Additionally, I bound SelectedItem to my ViewModel.  It seems the first time a row is clicked, it it correctly passes the User object to the property on the ViewModel.  However, every other time a row is clicked, it passes null to the property.

I will try to cut out this part for my code to simplify it and submit it to support as you suggested.

Thanks,
Glenn
0
Vanya Pavlova
Telerik team
answered on 11 Jan 2011, 06:01 PM
Hello Glenn,

 
Actually we need this part of the code which can help us to reproduce such a behavior.
Thank you!

Best wishes,
Vanya Pavlova
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
Tags
GridView
Asked by
Glenn
Top achievements
Rank 1
Answers by
Vanya Pavlova
Telerik team
Glenn
Top achievements
Rank 1
Share this question
or