編輯

共用方式為


Office Add-ins JavaScript API reference

The JavaScript API for Office enables you to create web applications that interact with the object models in Office host applications. Use this section to learn more about the classes, methods, and other types available for building Office Add-ins.

The following is a list of APIs for the supported Office host applications. Common API links include all APIs not attributed to a particular host (as detailed in Office Common API requirement set). Other items link to a version of the API reference documentation for that host based on a requirement set. The reference documentation will be versioned to include all APIs up to and including that requirement set (for example, ExcelApi 1.3 shows APIs in ExcelApi 1.1, 1.2, 1.3 as well as the Common APIs).

Tip

You can change the version of a reference page by using the filter selection drop-down menu above the table of contents at any time. If the page doesn't exist in that particular version, you'll be returned to the current version.

Office hosts

Special requirement sets

Online-only and desktop-only requirement sets are special requirement sets. An online-only requirement set contains the latest APIs for the web version of the supporting applications (currently Excel and Word). A desktop-only requirement set contains the latest APIs for the Windows and Mac versions of the supporting applications (currently Word). WordApiDesktop requirement sets are also supported on iPad. APIs in these requirement sets aren't fully supported across all platforms. For more information, see one of the following as applicable.

Note

If you're looking for the JavaScript APIs for developing Office Scripts, visit the Office Scripts API reference.

License terms

Use of the Office.js API library is governed by the terms described under the Microsoft software license terms for the Microsoft Office JavaScript (Office.js) API library.

See also