'Simple' question about number types...

Results 1 to 2 of 2

Thread: 'Simple' question about number types...

  1. #1
    Join Date
    Dec 1969

    Default 'Simple' question about number types...

    Its with a heavy heart that I post a question of this sort on these forums.. unfortunately, my brain is working on about 3 hours of sleep, and for the life of me, I cant remember what should be a simple VBScript function...<BR><BR>How can I go about testing a number type (interger, fraction)?<BR><BR>As part of a validation routine, i need to know if a certain number in my loop (when divided by 10) is a whole number or not..<BR><BR>Can I use something line !int or if (double(number) = false)...<BR><BR>Again, sorry for the simple question... but my brain hurts, and my search of the forums and faqs produced little results..<BR><BR>Any help would be appreciated...<BR><BR>s<BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: 'Simple' question about number types

    Maybe I&#039;m being stupid too and theres a simple function, but failing that I might do the heavy handed thing and have something like:-<BR><BR>myNumber=20<BR>if instr(cstr(myNumber/10),".") then<BR> &#060;!-- the number isn&#039;t whole when divided by 10 --&#062;<BR>else<BR> &#060;!-- the number is whole when divided by 10 --&#062;<BR>

Posting Permissions

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