I need same help. I navigate in internet I didnt find.
How can I convert all these textbox to decimal. Even the last result should display a decimal number.
private void lblTotal1_TextChanged(object sender, EventArgs e)
{
decimal d1, d2, d3, d4, total;
decimal.TryParse(lblTotal1.Text, out d1);
decimal.TryParse(lblTotal2.Text, out d2);
decimal.TryParse(lblTotal3.Text, out d3);
decimal.TryParse(lblTotal4.Text, out d4);
total = d1 + d2 + d3 + d4;
lblTotal.Text = total.ToString();
}