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

Grid update

7 Answers 108 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Daniel
Top achievements
Rank 1
Daniel asked on 06 Aug 2013, 02:05 PM

Hello, 

I need to update te value of a cell in my radgrid view. When I try to change it the grid does not uptate its value until I reagroup or manipulate the grid in any other way

This is my code:

selectedItem = TryCast(Me.rgv_attributes.Items.Item(0), c_accionAtributo)
Me.rgv_attributes.Items.EditItem(selectedItem)
selectedItem.Value = "algo"
Me.rgv_attributes.Items.CommitEdit()


The itemsource is an ObservableCollection(Of c_accionAtributo) 
Me.rgv_attributes.ItemsSource = atributes


Any help?

Thanks!





7 Answers, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 06 Aug 2013, 02:26 PM
Hello,

I have tested the code snippet you shared and both the values in the row and the group row were updated. Would you please share how have you configured your RadGridView? 

Regards,
Didie
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Daniel
Top achievements
Rank 1
answered on 06 Aug 2013, 02:35 PM
Here is my code:


<telerik:RadGridView Margin="12" Name="rgv_attributes" ColumnWidth="*" AutoGenerateColumns="False" IsSynchronizedWithCurrentItem="True" CellEditEnded="rgv_attributes_CellEditEnded">
</telerik:RadGridView>


            Dim typeColumn As New GridViewDataColumn()
            typeColumn.DataMemberBinding = New System.Windows.Data.Binding("Type")
            rgv_attributes.Columns.Add(typeColumn)
 
 
            Dim valueColumn As New GridViewDataColumn()
            valueColumn.DataMemberBinding = New System.Windows.Data.Binding("Value")
            rgv_attributes.Columns.Add(valueColumn)
 
            Dim comboColumn As New GridViewComboBoxColumn()
            comboColumn.DataMemberBinding = New System.Windows.Data.Binding("Action")
            comboColumn.ItemsSource = AvailableGenders
            comboColumn.Width = 100
 
            rgv_attributes.Columns.Add(comboColumn)
 
 
 
            Me.rgv_attributes.ItemsSource = atributes
 
 
            Me.rgv_attributes.GroupDescriptors.Add(New ColumnGroupDescriptor() With { _
 .Column = Me.rgv_attributes.Columns("Type"), _
 .SortDirection = System.ComponentModel.ListSortDirection.Descending _
})

Thanks


0
Daniel
Top achievements
Rank 1
answered on 07 Aug 2013, 06:43 AM
Hello,

Any idea of why is this happening?
0
Dimitrina
Telerik team
answered on 07 Aug 2013, 10:08 AM
Hello,

Thank you for sharing that additional information.

Unfortunately I am still not able to reproduce an issue. This would happen if you have set Asynchronous DataLoadMode, but this is not your case.
Would it be possible for you to isolate the issue in a demo project and send it to me? You can open a support ticket and attach the solution there.

Regards,
Didie
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Daniel
Top achievements
Rank 1
answered on 07 Aug 2013, 11:50 AM
Hi again, 

I've just submitted a ticket  ID : 724100

Thanks!
0
Dimitrina
Telerik team
answered on 07 Aug 2013, 01:37 PM
Hi,

Thank you.

I am posting my answer here as well:

The reason why the data is not updated is that your class (c_accionAtributo) does not implement the INotifyPropertyChanged interface. 

You can check this msdn article for a reference on how to implement it. 

Regards,
Didie
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Daniel
Top achievements
Rank 1
answered on 07 Aug 2013, 02:16 PM
Thanks a lot!! :)
Tags
GridView
Asked by
Daniel
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Daniel
Top achievements
Rank 1
Share this question
or