Int in VB6

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

    #1

    Int in VB6

    Hi
    Dim A
    Dim B
    A=25
    B=Int(A)

    B became 24

    Why ??
    /Bo
  • jamie

    #2
    Re: Int in VB6

    Bo wrote:[color=blue]
    > Hi
    > Dim A
    > Dim B
    > A=25
    > B=Int(A)
    >
    > B became 24
    >
    > Why ??
    > /Bo[/color]

    B was 25 for me using your code

    Try the following:

    Dim A As Integer
    Dim B As Integer
    A = 25
    B = CInt(A)

    Comment

    Working...