Skip to content

AddField

Adds a field.

1
myInlineCollection.AddField(fieldType: ( "Page" | "CreateDate" | "DisplayBarcode" ), options?: ( object | BarcodeFieldOptions )):Field

Parameters

( "Page" | "CreateDate" | "DisplayBarcode" ) fieldType
    The field type.

( object | BarcodeFieldOptions ) options optional
    Field options.

Returns

The new field.

Remarks

Only these field types are supported; any other type throws an error:

  • 'Page': the current page number, typically used in headers and footers.
  • 'CreateDate': the creation date of the document.
  • 'DisplayBarcode': a barcode or QR code. options must contain Type and Value; see BarcodeFieldOptions.

See Also