+ Reply to Thread
Results 1 to 3 of 3

Determine if a character is numeric or non-numeric

  1. #1
    AP
    Guest

    Determine if a character is numeric or non-numeric

    Is there a more efficient way to determine if a single character is a
    number versus a non-number?

    I use the ASC() function to check for the ASCII values between 48-57?

    Thanks in advance


  2. #2
    Edwin Tam
    Guest

    RE: Determine if a character is numeric or non-numeric

    Your method is one of the "safest" methods.

    Someone may suggest a more "standard" method of using "Isnumeric", for
    example:

    Isnumeric("1")

    However, this is not always "safe", especially in older versions of Excel
    (e.g. Excel 5 and 97) Therefore, to test single characters, it's not worth
    taking the risk. So, I think using the ASC test is more safe.

    Regards,
    Edwin Tam
    [email protected]
    http://www.vonixx.com



    "AP" wrote:

    > Is there a more efficient way to determine if a single character is a
    > number versus a non-number?
    >
    > I use the ASC() function to check for the ASCII values between 48-57?
    >
    > Thanks in advance
    >
    >


  3. #3
    NickHK
    Guest

    Re: Determine if a character is numeric or non-numeric

    AP,
    If you wish to be pedantic, what does "½" or "?" mean to you ?

    Nick


    "AP" <[email protected]> wrote in message
    news:[email protected]...
    > Is there a more efficient way to determine if a single character is a
    > number versus a non-number?
    >
    > I use the ASC() function to check for the ASCII values between 48-57?
    >
    > Thanks in advance
    >




+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1