.NET Based OPC UA Client/Server SDK  3.3.3.537
Monitored Items – Delete Monitored Items

Prerequisites

A session and a subscription with the server must be established.

Description

The following dialog shows an example dialog for deleting monitored items. Press the button “Show Code” to display the corresponding code, and the button “Help” to show this documentation page.

clienttutorials_delete_monitored_items.png

All currently monitored items are shown in the list at the bottom of the dialog window. Check the box in front of the items to be deleted and press the button “Delete”. Check the box in front of “Use Asynchronous Pattern” to call “BeginDelete” instead of “Delete”.

Sample Code

The following code deletes the specified monitored items. You can call DeleteMonitoredItems for a list of MonitoredItems. The monitored items and the method to call must belong to the same subscription. The selected monitored will be deleted at the server and removed from the subscription on client side.

// delete monitored items.
List<StatusCode> results = m_subscription.DeleteMonitoredItems(
monitoredItems,
new RequestSettings() { OperationTimeout = 10000 });