Word.Interfaces.FieldUpdateData interface

An interface for updating data on the Field object, for use in field.set({ ... }).

Properties

code

Specifies the field's code instruction.

data

Specifies data in an "Addin" field. If the field isn't an "Addin" field, it is null and it will throw a general exception when code attempts to set it.

locked

Specifies whether the field is locked. true if the field is locked, false otherwise.

result

Gets the field's result data.

showCodes

Specifies whether the field codes are displayed for the specified field. true if the field codes are displayed, false otherwise.

Property Details

code

Specifies the field's code instruction.

code?: string;

Property Value

string

Remarks

[ API set: WordApi 1.4 ]

Note: The ability to set the code was introduced in WordApi 1.5.

data

Specifies data in an "Addin" field. If the field isn't an "Addin" field, it is null and it will throw a general exception when code attempts to set it.

data?: string;

Property Value

string

Remarks

[ API set: WordApi 1.5 ]

locked

Specifies whether the field is locked. true if the field is locked, false otherwise.

locked?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi 1.5 ]

result

Gets the field's result data.

result?: Word.Interfaces.RangeUpdateData;

Property Value

Remarks

[ API set: WordApi 1.4 ]

showCodes

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Specifies whether the field codes are displayed for the specified field. true if the field codes are displayed, false otherwise.

showCodes?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]