最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

c# - Calculating the Irr using ExcelFinancialFunctionsCore with more than 512 payments overflows the function - Stack Overflow

programmeradmin3浏览0评论

I'm trying to make an app that calculates the payments of a credit, and I tried using ExcelFinancialFunctionsCore nuget for it. The payments can be calculated without problem but when trying to show the Irr to the client and the amount of payments surpass 512, the function stops working. The reason I has that amount of payments it's because of credits with a payment frecuency of weeks. Are there any alternatives to this package or a formula of some sorts that I could implement?

Here's my current solution but I would like to know if it could be done differently:

try
{
    Cover.Irr = (decimal)Financial.Irr(payments);
}
catch
{
    Cover.Irr = 0;
}

I would expect to stop using the catch because I would not like to handle exceptions if so, I would change it to an If that evaluates the length of the payments and don't execute said function

与本文相关的文章

发布评论

评论列表(0)

  1. 暂无评论