Skip to main content
Version: 2021.1

External Form Field

The main purpose of External Form Field is embedding an external application within your Modern form. You can use our JS API in them, which gives the most possibilities. By using the JS API you can control the behavior of the entire form. For everything to work properly, the embedded page must use the same protocol as the form it is embedded in (default https). This field type is available only for processes that use the Modern form display mode. In order to use the newly configured plugin, first add a new form field to a process and then select Custom control (External) as its type.

ExternalControl

In the configuration of this field you can provide the address of the application you want to display, JSON that will be used to configure the field, and choose where to place the field name. All actions, including reading configuration, are performed by JS API.

ExtControlConfig

Here are some examples of JS API:

  • Reading JSON given in configuration
Window.webcon.document.getSelfConfiguration(callback)

To the callback method will be passed JSON with the configuration property. In this property there will be JSON which we specified in the configuration.

  • Set/get fields values
window.webcon.fields.setValue(fieldName, value, options)
window.webcon.fields.getValue(fieldName, options, callback)

To the callback method will be passed field value.

  • Hide/show fields
window.webcon.fields.showField(fieldName)
window.webcon.fields.hideField(fieldName)
  • Set CustomControl height
window.webcon.window.setHeight(height)
  • Add attachment to form
window.webcon.document.addFile(file, categoryId)

For more information, see the JS API documentation.