Skip to main content
This event can only be processed by apps. Sending this event to an iframe that contains a non-app Omni URL, such as a dashboard, will have no effect on the embedded page.
Updates one or more document controls on an embedded app, without a reload. This event doesn’t have an effect if document controls are disabled.

Properties

object
Control values to set, as an object of control ID to value, in the same form omni.setControl() accepts. An ID that doesn’t match any control on the app is ignored.
A value from app:control-changed’s controls payload can be sent back here as-is.
string[]
An array of control IDs to clear. Omni applies each entry through omni.clearControl(). An ID that appears in both controls and clearControls is set, not cleared.

When to send this event

Send this event after Omni emits page:ready. If the app isn’t ready when the event arrives, Omni keeps the event and applies it once the app is ready:
  • If you send more than one event, Omni applies the events in the order that you sent them. If two events set the same control, the later event wins.
  • If you send a navigate event, Omni discards the controls that are still waiting for the page the user leaves.
  • If you send this event after a navigate event, Omni applies the controls to the app where the navigation lands. If the navigation lands on a page without an app, Omni drops the controls.

Example

This example sets a brand control directly and clears a region control: