Explanation is when if the last input is (.) then i can't keep pressing the (.)button, else if there's value then i can only press (.)button.
This is my code.
string input = "";
if (input.EndsWith("."))
{
}
else
{
lblExpression.Text = lblExpression.Text + Decimal.Text;
}
Is there any logic wrong with me?
Aucun commentaire:
Enregistrer un commentaire