Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
RETURN key in VS2005
Message
From
08/09/2006 12:10:17
 
 
To
07/09/2006 04:20:50
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
C# 2.0
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01151214
Message ID:
01152359
Views:
28
Richard,

Now you've got me confused. You're showing code for a KeyPress eventhandler, not a KeyDown eventhandler. Are you saying that you changed from using the KeyDown event to using the KeyPress event? And that it works now?

Certain of the "special" keys, like Enter, Tabs and the like, are sometimes a little more tricky to capture. I just recently learned (a week or two ago) that the KeyUp event works much better for those tricky keys. Now, I'm not talking about the Compact Framework, I haven't developed anything on Pocket PC's at all, but perhaps the same principle might apply here (using KeyUp instead).

~~Bonnie



>Apparently KeyDown does not capure a Return in PocketPC 2005 (but does in 2003)
>The code is
>private void txtRackR_KeyPress (object sender, KeyPressEventArgs e)
>
>{
>
>Keys key = (Keys)e.KeyChar;
>
>if (key == Keys.Enter)
>
>{
>
>scanRackR();
>
>
>}
>
>
>
>}
>
>And it works perfectly
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform