Results 1 to 3 of 3

Thread: Overflow

  1. #1
    Join Date
    May 2013

    Lightbulb Unanswered: Overflow

    Am creating a store managemaent system using Access 2003. On doing multiplication when the answer is more than 2 billions am getting message "Run-time error 6" Overflow.
    Here is the codes

    Private Sub txtvalue_Click()
    Dim num As Long, x As Long, y As Long

    x = CLng(txtuvalue)
    y = CLng(txtquantity)

    Me.txtvalue= x * y
    End Sub

    Does it mean Access 2003 can perform multiplication to an answer of 2 billion only??
    Thanks for your consideration.

  2. #2
    Join Date
    Feb 2004
    In front of the computer
    Provided Answers: 54
    No, the limit applies only to long as explained at The Integer, Long, and Byte Data Types

    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

  3. #3
    Join Date
    May 2013
    Thanks a lot. I've used Currency data type and it works.

Posting Permissions

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