CUMIPMT
Returns the cumulative interest paid between two periods.
Syntax
expression.CUMIPMT(arg1, arg2, arg3, arg4, arg5, arg6);
expression
- A variable that represents a ApiWorksheetFunction class.
Parameters
Name | Required/Optional | Data type | Default | Description |
---|---|---|---|---|
arg1 | Required | ApiRange | ApiName | number | The interest rate for the investment. | |
arg2 | Required | ApiRange | ApiName | number | The total number of payment periods. | |
arg3 | Required | ApiRange | ApiName | number | A present value of the payments. | |
arg4 | Required | ApiRange | ApiName | number | The first period included into the calculation. | |
arg5 | Required | ApiRange | ApiName | number | The last period included into the calculation. | |
arg6 | Required | ApiRange | ApiName | number | The timing of the payment. |
Returns
number
Example
- Code
- Result
let worksheet = Api.GetActiveSheet();
let func = Api.GetWorksheetFunction();
worksheet.GetRange("A1").SetValue(func.CUMIPMT(0.1/12, 2*12, 2000, 1, 24, 0));