

NPV() - Net present value
| Type
| Field
| Description
|
| double
| dInitial
| Initial investment
|
| double
| dInt
| Interest percentage
|
| double
| dCF[]
| Array of cash flows
|
| integer
| iCount
| Number of cash flows in array
|
| integer
| iBasis
| Value:
0 = end 1 = begin |
PowerBuilder Function declaration
function double NPV(double dInitial, double dInt, double dCF[], int iCount, int iBasis) library "IFL16.DLL"
Visual Basic Function declaration
Declare Function NPV lib "IFL16" (ByVal dInitial As Double, ByVal dInt As Double, ByVal dCF[] As Double, ByVal iCount As Integer, ByVal iBasis As Integer) As Double
Access Function declaration
Declare Function NPV lib "IFL16" (ByVal dInitial As Double, ByVal dInt As Double, dCF As Any, ByVal iCount As Integer, ByVal iBasis As Integer) As Double
C/C++ Synopsis
#include "function.h"
double NPV(double dInitial, double dInt, double *dCF, int iCount, int iBasis)
32 bit DLL declarations
PowerBuilder Function declaration
function double NPV(double dInitial, double dInt, double dCF[], int iCount, int iBasis) library "IFL32.DLL"
Visual Basic Function declaration
Declare Function NPV lib "IFL32" (ByVal dInitial As Double, ByVal dInt As Double, ByVal dCF[] As Double, ByVal iCount As Integer, ByVal iBasis As Integer) As Double
Access Function declaration
Declare Function NPV lib "IFL32" (ByVal dInitial As Double, ByVal dInt As Double, dCF As Any, ByVal iCount As Integer, ByVal iBasis As Integer) As Double
C/C++ Synopsis
#include "function.h"
double NPV(double dInitial, double dInt, double *dCF, short sCount, short sBasis)
Example:
| dInitial
| =
| 0
|
|
| dInt
| =
| 0.07
| (7%)
|
| dCF[1]
| =
| 1,600
|
|
| dCF[2]
| =
| 1,600
|
|
| dCF[3]
| =
| 1,600
|
|
| dCF[4]
| =
| 1,700
|
|
| dCF[5]
| =
| 1,700
|
|
| iCount
| =
| 5
|
|
| iBasis
| =
| 0
|
|