Math.Round with IRR : Number Function « Data Type « VB.Net Tutorial






Option Strict On

Public Module modMain
   Public Sub Main()
      Dim cashFlow() As Double = {-102450.55, -30967.12, 134.85, 82930.91, _
                                  121766.18, 90345.58, 125093.16}
      Dim guess As Double = .15
      Console.WriteLine("{0}", Math.Round(IRR(cashFlow, guess)*100,1))
   End Sub
End Module
31.1%








2.44.Number Function
2.44.1.CInt
2.44.2.Fix
2.44.3.Math.Round with IRR
2.44.4.CInt: convert Hexadecimal in string to int