RangeValidator and CompareValidator does not recognize scientificnotation

Discussion in 'ASP .Net' started by Andrew Han, Jan 23, 2008.

  1. Andrew Han

    Andrew Han Guest

    I have a simple textbox where a user can enter a numeric value.

    The RangeValidator works perfectly well to determine if the value is a
    number of whatever type I specify AND to determine if the value sits
    between the min and max values I specify.

    However, if the user enters a valid number within the specified range,
    but enters it in scientific notation, the RangeValidator doesn't
    recognize it as a valid number.

    Example:

    the RangeValidator checks to make sure the entered value is an Integer
    between 0 and 1000. The user enters "3e2"... a valid number in that
    range, but the RangeValidator fails....

    How can i get it to recognize scientific notation?

    thanks.
     
    Andrew Han, Jan 23, 2008
    #1
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.