how to truncate an double datatype value variable
Posted
by prince23
on Stack Overflow
See other posts from Stack Overflow
or by prince23
Published on 2010-05-15T12:43:20Z
Indexed on
2010/05/15
12:54 UTC
Read the original article
Hit count: 180
c#
hi, i have an class
public class Score
{
public double marks { get; set; }
}
now in my code
List<Level1> Obj= new List<Level1>();
Score Object= new Score();
l1.marks=94.345454;
Obj.Add(Object)
// now whiling adding the object to list i need to trunacte the value to
94.34 and store in the list obj.
so that i need to get output has 94.34
how can i do it.
thanks in advance
prince
© Stack Overflow or respective owner