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

[Solved] selecteditem with domaindatasource

1 Answer 118 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.
Marc BAB
Top achievements
Rank 1
Marc BAB asked on 28 Jan 2010, 04:51 PM
How to synchronise the selectitem between a wcf ria domaindatasource and a dataform:

 

 

<telerikGridView:RadGridView IsBusy="{Binding IsLoadingData, ElementName=WcfRiaDomainDataSource}"

 

ItemsSource="{Binding Data, ElementName=WcfRiaDomainDataSource}"

 

 

SelectionMode="Single"

 

 

 

SelectedItem="{Binding DataView.CurrentItem, ElementName=WcfRiaDomainDataSource, Mode=TwoWay}"

 

 

/>

 

 

 

<dataFormToolkit:DataForm x:Name="df"

 

 

 

 

 

ItemsSource="{Binding Data, ElementName=WcfRiaDomainDataSource}"

 

 

 

 

 

 

SelectedItem="{Binding DataView.CurrentItem, ElementName=WcfRiaDomainDataSource, Mode=TwoWay}"

 

 

 

 

 

/>
It's ok between dds and dataform, but the dds.CurrentItem is not moved when I select another row in the RadGridView.
Thanks in advance

 

1 Answer, 1 is accepted

Sort by
0
Milan
Telerik team
answered on 29 Jan 2010, 02:30 PM
Hi Marc BAB,

Currenly the CurrentItem of RadGridView is not synchronized with the CurrentItem of the source collection view. We are already working on implementing this functionality and we expect to complete the task in one or two weeks. I have created a PITS item that will allow you to track this issue and be notified when its status changed.

For the time being you could use the following workaround - subscribe for SelectionChanged event and update the CurrentItem of the source view manually:

private void RadGridView_SelectionChanged(object sender, SelectionChangeEventArgs e)
{
    this.domainDataSource.DataView.MoveCurrentTo(this.gridView.SelectedItem);
}


Regards,
Milan
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
GridView
Asked by
Marc BAB
Top achievements
Rank 1
Answers by
Milan
Telerik team
Share this question
or