Private Sub Button_Click_2(sender As Object, e As RoutedEventArgs) Dim dr As DataRow dr = dtGrid.NewRow() dr("Status") = 4 dr("ID") = "0" dr("Name") = "" dr("CountryId") = "0" dtGrid.Rows.Add(dr) DG.SelectedItem = dtGrid.Rows.Count - 1 '' Make the ID field the current column of the grid DG.CurrentColumn = DG.Columns(1) '' Put the grid into editing mode DG.BeginEdit() '' Give the grid control focus DG.ScrollIntoView(dr) DG.BeginEdit() end sub
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)