Excel- Type check- VBA coding

  Neet_8 21:02 31 Jan 2008

I have created a user form in which i have added VBA coding to prevent the possibility of the user being able to insert letters into the field. At current i have inserted the following cases:
Case 32, 48 To 57

What case do i need to insert in order to allow the user to insert a dot ('.') into a text box on a user form. This field is for a price and therefore, a dot is required so that the price can be separated and placed to two decimal places-e.g. 45.99

Thanks your help would be appreciated!

  VoG II 21:18 31 Jan 2008


Case 32, 46, 48 To 57

but it might be better to invert your logic and exclude the ANSI codes for numbers - 48-57.

  VoG II 21:20 31 Jan 2008

Ignore my last comment - I was thinking of another similar question.

  Simsy 22:25 31 Jan 2008

keyascii ??



  Simsy 22:43 31 Jan 2008

the the full stop is 46

Apologies if I'm way off base!!



This thread is now locked and can not be replied to.

Elsewhere on IDG sites

Xiaomi Mi Mix 2 review

What went wrong at the Designs of the Year 2017

iPhone X news: Release date, price, new features & specs

Comment regarder des séries et talk-shows américains en France ?