> private void Form1_KeyPress(object sender, KeyPressEventArgs e)
> {
> if (e.KeyChar == (char)27)
> Application.Exit();
> }
If you are going to follow this technique, Eric (and it seems from your
other post you're not), I'd recommend handling instead the KeyDown event,
and comparing against Keys.Escape rather than the above.
Noting also, of course, that for simply closing a dialog box, calling
Application.Exit() is probably overkill. :)
Pete
WP - 14 Mar 2008 23:42 GMT
> > private void Form1_KeyPress(object sender, KeyPressEventArgs e)
> > {
[quoted text clipped - 10 lines]
>
> Pete
No, I am not going down that road even though I appreciate people
trying to help me. But I can't help thinking that that code looks like
my very simple key handlers I wrote in pure C when doing glut-
programming. :)