private decimal Format(decimal price) { var power = (decimal) Math.Pow(10, _precision); var mid = (int) (price*power); return mid/power; } }