Int64 outside range of the Integer setting on Compare Validator

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi there,

How can I validate large numbers that are too big for int32 which
Comparevalidator uses. Int64 can handle the value 9999999999999999999 (18
nines).

Help!

Many thanks,

Jono
 
Hi Jono,

Is it possible for you to convert it to string and then make the
validation?
 
I could try...you mean convert to string, then test for string only
containing numbers?
 
It already is a string. The CompareValidator converts the string to a
number when it does the verification.

You can use a RegularExpressionValidator with the pattern "\d+" to
verify that the field only contains digits.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top