Hi everyone
I am new to programming and learning slowly. I have added some code to calculate monthly payment, but I am getting a divide by 0 error even though I am not dividing by 0.
How can I resolve this.
My code:
if (FinancingRateTable.FinancingRate == 0.00)
{
return (element.dspAmtFinance()/(36)); <--When month is hardcoded No error is present
//return (element.dspAmtfinance()/(FinancingTermTable.Months)); <-- this way, I get error
}
when I return 'FinancingTermTable.Months' i get my terms in month, what I dont understand is how I get a divide by 0 error, please enlighten me on this...
Thanks,
G
*This post is locked for comments
I have the same question (0)