How can we navigate from one cell to another using the tab?
Thanks.
This is because you change all of the default functionality like focusing, navigating etc. We usually recommend copy and paste the default CellValuePresenter style and then making some modifications to it but in your case you don't have to retemplate the CellValuePresenter for the validation logic. You can achieve the same behavior by changing the default editor of the field (EditorType) and apply the validation with a custom style (EditorStyle) :
<igDP:Field.Settings>
<igDP:FieldSettings EditAsType="{x:Type igEditors:XamMaskedEditor}">
<igDP:FieldSettings.EditorStyle>
<Style TargetType="{x:Type igEditors:XamMaskedEditor}">
<Setter Property="ValueConstraint">
<Setter.Value>
<igEditors:ValueConstraint MaxLength="50"/>
</Setter.Value>
</Setter>
</Style>
</igDP:FieldSettings.EditorStyle>
</igDP:FieldSettings>
</igDP:Field.Settings>
You may also find helpfull the following articles:
http://community.infragistics.com/wpf/articles/validation-in-the-xamdatagrid.aspx
http://blogs.infragistics.com/blogs/andrew_smith/archive/2009/03/27/hosting-wpf-controls-in-a-xamdatagrid-cell.aspx
OK. Then, this behavior does not work when changing the CellValuePresenter?
Hello, this is already the default behavior of the grid. When you press the Tab key you should be able to navigate between the cells in the grid. You might also want to check the build in DataPresenterCommand sample in the Feature Browser:
XamDataGrid-->DataBinding and Interaction-->xamDataGrid Commands
Let me know if you have any questions on this matter.