Link to home
Start Free TrialLog in
Avatar of TheRaven
TheRaven

asked on

How to use MaskEdit to ensure a correct number input

Hi!

I am working on a program where I need to be absolutly sure that the number i receive is 11 numbers no more no less.

I have fumbled around with MaskEdit and EDBEditError exceptions, but I am rather uncertain how to use this correctly.

I would like to know if I am all wrong in assuming that I have to use exceptions and how to use them correct.
ASKER CERTIFIED SOLUTION
Avatar of RBertora
RBertora
Flag of United Kingdom of Great Britain and Northern Ireland 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
hmm,

if you place a mask like

00000000000

then the user cant leave the field, if there are less than 11 digits entered.

no special check must be done

meikl
Meikl! I always seem to learn something new from you :-)

Raven please reject my answer as Kretzschmars is much neater!
Rob ;-)
Avatar of TheRaven
TheRaven

ASKER

Hi RBertora

Well your answer was'nt that bad, I somehow tried alot of wrong ways to test the length of the text, just not the way you mentioned, so thanks for that.

I was avare of the MaskEdit options explained by Meikl so you gave me more information ;-)

TheRaven
Thanks Raven,
I hope Meikl doesn't feel too bad :-(
Rob ;-)
nope rob,

i be happy to see you at the top15 soon.
now one step nearer ;-)

meikl
Very happy to hear that
thanks Meikl :-)