decimal total = 2m; decimal discount = 0.2m; decimal disPercent = discount / total;
decimal total = 2m; decimal discount = 0.2m; decimal disPercent = decimal.Divide(discount, total);
0.2 / 2.0 == 2.0 / 20.0 == 1.0 / 10.0 == 0.1
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)