Search code examples
wpfwpfdatagridrotationarrow-keys

Rotate the DataGrid, how to Rotate the direction / arrow keys


We have rotated our DataGrid by "-90" successfully. However, The arrow keys stayed as not rotated.

For example, When we press the UP-Arrow-key it goes left, instead UP, etc.

How can we rotate the Arrow keys to reflect the actual directions of the screen?

Thanks much for your help.


Solution

  • Can't imagine what for you've rotated dataGrid, but you can catch the keypress event and transform it to another key press (for example, left transform to up) like in this thread:

    Simulating Key Press c#