Skip to main content

beforeHide

fires before a control or its radio button is hidden

beforeHide: (value: string, id?: string, init: boolean) => boolean | void;

Parameters:

  • value: string - the current value of the control
  • id?: string - optional, the ID of the radio button of the control
  • init: boolean - true, if the event is triggered on the control initialization; otherwise, false

Returns:

Return false to prevent a control or its radio button from being hidden; otherwise, true.

Example

form.getItem("radiogroup").events.on("beforeHide", function(value, id, init) {
console.log("beforeHide", value, id, init);
return true;
});

Related sample: Form. Hide/Show control

Change log:

  • The id parameter was added in v8.0
  • The event was added in v7.0