コード例 #1
0
        public void UnSubcribe()
        {
            try
            {
                opcSubscription.DataChanged -= opcSubscription_DataChanged;
                server.CancelSubscription(opcSubscription);
                opcSubscription.Dispose();

                monitoredTags.Clear();
                OnReportMessage("OPC Subscription cleared");
            }
            catch (Exception ex)
            {
                OnReportMessage(ex.Message.ToString());
            }

            RefreshServerStatus();
        }