3
Answers

How to check zero of newly creation object

Mark Tabor

Mark Tabor

3y
658
1

 var charge = charges.Create(new ChargeCreateOptions
            {
             
                 Amount = (long)transectionModel.Charge * 100,
                Description = "Test Payment",
                Currency = "USD",
                Customer = customer.Id
            });

 

when amount is zero code thorow exception how to handle ZERO in amount variabel 

Answers (3)