跳到主要内容

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

NameRequired/OptionalData typeDefaultDescription
arg1RequiredApiRange | ApiName | numberThe interest rate for the investment.
arg2RequiredApiRange | ApiName | numberThe total number of payment periods.
arg3RequiredApiRange | ApiName | numberA present value of the payments.
arg4RequiredApiRange | ApiName | numberThe first period included into the calculation.
arg5RequiredApiRange | ApiName | numberThe last period included into the calculation.
arg6RequiredApiRange | ApiName | numberThe timing of the payment.

Returns

number

Example

let worksheet = Api.GetActiveSheet();
let func = Api.GetWorksheetFunction();
worksheet.GetRange("A1").SetValue(func.CUMIPMT(0.1/12, 2*12, 2000, 1, 24, 0));