#2 When I click the button I want to navigate to another page and display the selected record from the datagrid.
<syncfusion:SfDataGrid x:Name="dataGrid"
Grid.Row="0"
AutoGenerateColumns="False"
AllowEditing="True"
<!--Binding selected item in grid-->
SelectedItem="{Binding SelectedItem, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
ItemsSource="{Binding GDCSource}"
ShowGroupDropArea="True"
ShowRowHeader="True"> |
Private Sub Button_Click(ByVal sender As Object, ByVal e As RoutedEventArgs)
Dim win As New Window2()
win.DataContext = (TryCast(Me.DataContext, PersonModel)).SelectedItem
win.Show()
End Sub |
<Grid >
<!--Binding LastName of selected items-->
<TextBlock HorizontalAlignment="Center"
VerticalAlignment="Center" Width="120" Height="50" Text="{Binding LastName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
</Grid> |