I know that I can use the code below to define the Enter key on the keyboard
if (e.Key == Key.Return) { // do something }
But I want to know what is the code for "+" and "-"?
Can anybody help me.
There are two sets. One on the keyboard and the other on the keyboard side.
To use keboard Key.OemPlus and Key.OemMinus , and for keyboard use Key.Add and Key.Subtract .
Key.OemPlus
Key.OemMinus
Key.Add
Key.Subtract
The entire list of keys is here: http://msdn.microsoft.com/en-us/library/system.windows.input.key.aspx
OemPlus and OemMinus are correct, as Nikil said.
OemPlus
OemMinus