Excel.Application class

Extends
OfficeExtension.ClientObject

Properties

calculationMode

Returns the calculation mode used in the workbook, as defined by the constants in Excel.CalculationMode. Possible values are: Automatic, where Excel controls recalculation; AutomaticExceptTables, where Excel controls recalculation but ignores changes in tables; Manual, where calculation is done when the user requests it.

API set: ExcelApi 1.1 for get, 1.8 for set ]

Methods

calculate(calculationType)

Recalculate all currently opened workbooks in Excel.

API set: ExcelApi 1.1 ]

load(option)

Queues up a command to load the specified properties of the object. You must call "context.sync()" before reading the properties.

suspendApiCalculationUntilNextSync()

Suspends calculation until the next "context.sync()" is called. Once set, it is the developer's responsibility to re-calc the workbook, to ensure that any dependencies are propagated.

API set: ExcelApi 1.6 ]

          toJSON()

Property Details

calculationMode 

Returns the calculation mode used in the workbook, as defined by the constants in Excel.CalculationMode. Possible values are: Automatic, where Excel controls recalculation; AutomaticExceptTables, where Excel controls recalculation but ignores changes in tables; Manual, where calculation is done when the user requests it.

API set: ExcelApi 1.1 for get, 1.8 for set ]

TypeScriptCopy
Property Value
Excel.CalculationMode | "Automatic" | "AutomaticExceptTables" | "Manual"

Method Details

calculate(calculationType) 

Recalculate all currently opened workbooks in Excel.

API set: ExcelApi 1.1 ]

TypeScriptCopy
Parameters
calculationType
Excel.CalculationType

Specifies the calculation type to use. See Excel.CalculationType for details.

Returns
void
Examples
JavaScriptCopy

load(option) 

Queues up a command to load the specified properties of the object. You must call "context.sync()" before reading the properties.

TypeScriptCopy
Parameters
option
string | string[]

A comma-delimited string or an array of strings that specify the properties/relationships to load.

Returns
Remarks

In addition to this signature, this method has the following signatures:

load(option?: { select?: string; expand?: string; }): Excel.Application - Where option.select is a comma-delimited string that specifies the properties/relationships to load, and options.expand is a comma-delimited string that specifies the relationships to load.

load(option?: { select?: string; expand?: string; top?: number; skip?: number }): Excel.Application - Only available on collection types. It is similar to the preceding signature. Option.top specifies the maximum number of collection items that can be included in the result. Option.skip specifies the number of items that are to be skipped and not included in the result. If option.top is specified, the result set will start after skipping the specified number of items.

Examples
JavaScriptCopy

suspendApiCalculationUntilNextSync() 

Suspends calculation until the next "context.sync()" is called. Once set, it is the developer's responsibility to re-calc the workbook, to ensure that any dependencies are propagated.

API set: ExcelApi 1.6 ]

TypeScriptCopy
Returns
void

toJSON() 

TypeScriptCopy
Returns

转载于:https://www.cnblogs.com/jaww/p/9534795.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值