We have a solution where we need be able to only tab between editable cells in a grid. The default behavior of the tab is to select the next cell in the grid. Is there any way to override this, so that clicking tab the grid will select the next editable cell in the grid?
Regards
Bjarne
I think I've found what is breaking my project. I did a new sample project to see what breaks it and found out that setting IsOnCellActiveEditingEnabled to True, breaks your code. Without that it works fine.
Can you try with IsOnCellActiveEditingEnabled=True and see if you can break your code? And of course if you can find a solution how to make it work with that too :) Thanks again!
Then there's probably something in my project that breaks it. I can post you some more details tomorrow when I get back to it. I can also try it on a test project to see if I can make it work there also.
anttisimonen,
The piece of code I posted yesterday works for non-grouped data, even your cleaned up version works pretty good in my test project. Once I get a little more time I'll try some deeper debugging to see if I can work in grouped rows as well.
More information. It seems that the "old" cell still remains in edit mode, even if I move the IsActive and IsSelected to another cell? That's probably the reason the grid changes the IsActive back to the old value over and over again.
I also tried it so that I first set the IsActive/IsSelected to false for the "to-be-skipped" cell and then set the new active cell when it comes back to ActiveCellChanged event. That didn't work either. Something is still changing it eventually back to the previous one. Any ideas?