Ejemplo n.º 1
0
 private void WriteOPCValue(OPCObject obj)
 {
     try
     {
         _OPCUtil.WriteAsync(getItemIdentifier(obj.itemIdentifier), getItemValue(obj.itemValue));
     }
     catch (Exception Ex)
     {
         MessageBox.Show(Application.Current.MainWindow, "Error, unable to write\n" + Ex.ToString());
     }
 }
Ejemplo n.º 2
0
        }//main one

        private void WriteOPCValue(OPCObject obj)
        {
            /**************************************************************************************************************
            *  -> Method     : WriteOPCValue
            *  -> Param	  : OPCObject obj
            *  -> Event      : This method is triggered whenever a write request is submitted, uses an EVENT called UpdatedSourceEvent
            *  -> Description: This method is used to write a value on the PLC
            **************************************************************************************************************/
            try
            {
                _OPCUtil.WriteAsync(GetItemIdentifier(obj.itemIdentifier), GetItemValue(obj.itemValue));
            }
            catch (Exception Ex)
            {
                MessageBox.Show(Application.Current.MainWindow, "Error, unable to write\n" + Ex.Message);
            }
        }