G
Guest
I have sub-classed the TextBox. In its OnKeyDown event I can intercept key
strokes, examine them, etc. When I get a certain keycode (e.g., 'A') I want
to change it to another unicode key from a different code page (e.g.,
"\u2801"). But the KeyCode, KeyData, and KeyValue properties of KeyEventArgs
are all only getters. They are read only and thus do not permit changing the
assigned KeyCode. My question is this: How do I change the KeyCode of the
KeyEvenetArgs to be a different key? I tired to call base.OnKeyDown() passing
a new instance of KeyEventArgs, but the constructor for KeyEventArgs() takes
an instance of Keys, and THAT constructor takes no argument. Even if I create
an instance of Keys, then I'm faced with the read only nature of KeyCode,
KeyData, etc. It seems to be a vicious circle. Any help would be appreciated.
strokes, examine them, etc. When I get a certain keycode (e.g., 'A') I want
to change it to another unicode key from a different code page (e.g.,
"\u2801"). But the KeyCode, KeyData, and KeyValue properties of KeyEventArgs
are all only getters. They are read only and thus do not permit changing the
assigned KeyCode. My question is this: How do I change the KeyCode of the
KeyEvenetArgs to be a different key? I tired to call base.OnKeyDown() passing
a new instance of KeyEventArgs, but the constructor for KeyEventArgs() takes
an instance of Keys, and THAT constructor takes no argument. Even if I create
an instance of Keys, then I'm faced with the read only nature of KeyCode,
KeyData, etc. It seems to be a vicious circle. Any help would be appreciated.