Type validation

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Samuel Shulman

    #1

    Type validation

    Is there method to verify that a value is integer and not double

    Thank you,
    Samuel


  • Marina Levit [MVP]

    #2
    Re: Type validation

    You can take its ceiling or floor, and compare it to the original value. If
    they are the same, then it is an integer.

    "Samuel Shulman" <samuel.shulman @ntlworld.comwr ote in message
    news:Oe3hJHasGH A.3556@TK2MSFTN GP03.phx.gbl...
    Is there method to verify that a value is integer and not double
    >
    Thank you,
    Samuel
    >
    >

    Comment

    • Samuel Shulman

      #3
      Re: Type validation

      Thanks



      "Marina Levit [MVP]" <someone@nospam .comwrote in message
      news:uxKXKLasGH A.2240@TK2MSFTN GP04.phx.gbl...
      You can take its ceiling or floor, and compare it to the original value.
      If they are the same, then it is an integer.
      >
      "Samuel Shulman" <samuel.shulman @ntlworld.comwr ote in message
      news:Oe3hJHasGH A.3556@TK2MSFTN GP03.phx.gbl...
      >Is there method to verify that a value is integer and not double
      >>
      >Thank you,
      >Samuel
      >>
      >>
      >
      >

      Comment

      • tommaso.gastaldi@uniroma1.it

        #4
        Re: Type validation

        Let's see if anyone guesses what is the
        ceiling of 10.000000000000 001D

        :)

        -tom

        Samuel Shulman ha scritto:
        Thanks
        >
        >
        >
        "Marina Levit [MVP]" <someone@nospam .comwrote in message
        news:uxKXKLasGH A.2240@TK2MSFTN GP04.phx.gbl...
        You can take its ceiling or floor, and compare it to the original value.
        If they are the same, then it is an integer.

        "Samuel Shulman" <samuel.shulman @ntlworld.comwr ote in message
        news:Oe3hJHasGH A.3556@TK2MSFTN GP03.phx.gbl...
        Is there method to verify that a value is integer and not double
        >
        Thank you,
        Samuel
        >
        >

        Comment

        • Samuel Shulman

          #5
          Re: Type validation

          11


          <tommaso.gastal di@uniroma1.itw rote in message
          news:1154029554 .988657.13780@i 3g2000cwc.googl egroups.com...
          Let's see if anyone guesses what is the
          ceiling of 10.000000000000 001D
          >
          :)
          >
          -tom
          >
          Samuel Shulman ha scritto:
          >
          >Thanks
          >>
          >>
          >>
          >"Marina Levit [MVP]" <someone@nospam .comwrote in message
          >news:uxKXKLasG HA.2240@TK2MSFT NGP04.phx.gbl.. .
          You can take its ceiling or floor, and compare it to the original
          value.
          If they are the same, then it is an integer.
          >
          "Samuel Shulman" <samuel.shulman @ntlworld.comwr ote in message
          news:Oe3hJHasGH A.3556@TK2MSFTN GP03.phx.gbl...
          >Is there method to verify that a value is integer and not double
          >>
          >Thank you,
          >Samuel
          >>
          >>
          >
          >
          >

          Comment

          • tommaso.gastaldi@uniroma1.it

            #6
            Re: Type validation

            :) try

            MsgBox(Math.Cei ling(10.0000000 00000001D))

            with both VB2003 and then with VB 2005. You will see at MS
            have changed opinion about the result :)

            -tom

            Samuel Shulman ha scritto:
            11
            >
            >
            <tommaso.gastal di@uniroma1.itw rote in message
            news:1154029554 .988657.13780@i 3g2000cwc.googl egroups.com...
            Let's see if anyone guesses what is the
            ceiling of 10.000000000000 001D

            :)

            -tom

            Samuel Shulman ha scritto:
            Thanks
            >
            >
            >
            "Marina Levit [MVP]" <someone@nospam .comwrote in message
            news:uxKXKLasGH A.2240@TK2MSFTN GP04.phx.gbl...
            You can take its ceiling or floor, and compare it to the original
            value.
            If they are the same, then it is an integer.

            "Samuel Shulman" <samuel.shulman @ntlworld.comwr ote in message
            news:Oe3hJHasGH A.3556@TK2MSFTN GP03.phx.gbl...
            Is there method to verify that a value is integer and not double
            >
            Thank you,
            Samuel
            >
            >

            Comment

            • Samuel Shulman

              #7
              Re: Type validation

              Any explanation?


              <tommaso.gastal di@uniroma1.itw rote in message
              news:1154033239 .853095.189720@ h48g2000cwc.goo glegroups.com.. .
              :) try
              >
              MsgBox(Math.Cei ling(10.0000000 00000001D))
              >
              with both VB2003 and then with VB 2005. You will see at MS
              have changed opinion about the result :)
              >
              -tom
              >
              Samuel Shulman ha scritto:
              >
              >11
              >>
              >>
              ><tommaso.gasta ldi@uniroma1.it wrote in message
              >news:115402955 4.988657.13780@ i3g2000cwc.goog legroups.com...
              Let's see if anyone guesses what is the
              ceiling of 10.000000000000 001D
              >
              :)
              >
              -tom
              >
              Samuel Shulman ha scritto:
              >
              >Thanks
              >>
              >>
              >>
              >"Marina Levit [MVP]" <someone@nospam .comwrote in message
              >news:uxKXKLasG HA.2240@TK2MSFT NGP04.phx.gbl.. .
              You can take its ceiling or floor, and compare it to the original
              value.
              If they are the same, then it is an integer.
              >
              "Samuel Shulman" <samuel.shulman @ntlworld.comwr ote in message
              news:Oe3hJHasGH A.3556@TK2MSFTN GP03.phx.gbl...
              >Is there method to verify that a value is integer and not double
              >>
              >Thank you,
              >Samuel
              >>
              >>
              >
              >
              >
              >

              Comment

              Working...