Link to home
Start Free TrialLog in
Avatar of Murray Brown
Murray BrownFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Visual Studio Tools for office 2005 KeyPress event

Hi

I am converting an Excel VBA project to Visual Studio Tools for Office 2005.
In the VBA project I use the following code in the KeyPress event of a text box
to prevent anything other than numbers being typed in
        'If KeyAscii < 48 Or KeyAscii > 57 Then KeyAscii = 0
What is the equivalent code in Visual Studio 2005 VB?

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Jaime Olivares
Jaime Olivares
Flag of Peru image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Murray Brown

ASKER

Thanks Jaime. Excellent answer!