remove

[ Function ]

public static remove(
    control: TcHmi.Controls.System.baseTcHmiControl,
    element: JQuery
): JQuery;

Removes an HTML element from the overlay area. If the element is not currently in the overlay area, it is returned without any changes. This function is intended for use from a control. If this is removed (detached) from the DOM, all elements are also removed from the TopMostLayer.

Parameter

Name

Type

Description

control

TcHmi.Controls.System.baseTcHmiControl

Calling control.

element

JQuery

JQuery collection with an HTML element.

Return value

Type

Description

JQuery

JQuery collection with the removed HTML element.

remove 1:

Available from version 1.10

Sample - JavaScript

var myPopup = $('<div style="background:white;padding:10px;">Hello World<div>');
TcHmi.TopMostLayer.add(this, myPopup);
TcHmi.TopMostLayer.remove(this, myPopup);