1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Rounding off number

Discussion in 'C#' started by sweet_babylhyn, Aug 31, 2010.

  1. sweet_babylhyn

    sweet_babylhyn New Member

    Aug 31, 2010
    Likes Received:
    Trophy Points:
    Hello guys,

    How can I get the round off number disregarding the next number specify in length of decimal places in math.round. Example, I want to round off 1.499 to 1.49 not 1.5.

    My program has a condition if the decimal places is more than .05, it will add 1. example 1.0521 will become 2. But if its 1.0498 will become 1.

    It is possible guys?

    Thanks in advance.

Share This Page