Problem with setting focus on WPF DataGridTextColumn

Feb 14, 2011 at 8:26 PM

Hi All

I have WPF DatGrid like below:

<DataGrid x:Name="MasterMemlinesDataGrid"
ItemSources= "{Binding MyItems}" 
SelectedItem= "{Binding SelectedItem}">
<DataGridTextColumn Width="110"
Binding="{Binding ItemCode}" />
<DataGridTextColumn Width="110"
Binding="{Binding ItemDescription}" />
<DataGridTextColumn Width="110"
Binding="{Binding ItemMainDescription}" />
</DataGrid.Columns> </DataGrid> 

Also I have a button which open a view and displays a list of item. After user selects a item, I will update the "ItemCodeTextColumn" and "ItemDescTextColumn" to display the select item, then set focus to the "ItemManiDescTextColumn" cell. Can anyone let me know how I can set the focus to the "ItemManiDescTextColumn" cell?

Thank you