I'm using WPF with vb.net. I want to capture a key press event of the '#' key. I'm using a german keyboard. But I wont this to work with different language settings.
Private Sub textbox_KeyDown(sender As Object, e As KeyEventArgs) Handles texbox.KeyDown
If e.Key.ToString() = "#" Then
'do stuff
End If
End Sub
e.Key.ToString() returns "OemQuestion"
Chr(e.key) returns "‘"
ChrW(e.key) returns ChrW(145)
The ASCII code for '#' is 35.
So would I do this?