CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 8 of 8

Thread: 51/2 = 26?

Threaded View

  1. #1
    Join Date
    Sep 2005
    Posts
    13

    51/2 = 26?

    51/2=26?

    Why visual basic rounds up this calculation. I want it to round it down in order to get the answer 25.

    How must I do in order to make vb rounding the calculation down.

    I have made like this:

    dim result as integer

    x=51
    result=x/2
    Last edited by JackiePaper; October 25th, 2005 at 07:16 AM.

Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured