分支自 SuZhouGuanHong/TaiYuanTaiZhong

dengjunjie
2024-01-31 50fd5cc9cfad08714c4daa6d481c5293ff2ae6b1
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WCS/WCSClient/DBExtension.cs
@@ -1,4 +1,5 @@
using System;
using OfficeOpenXml.FormulaParsing.Excel.Functions.Text;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -56,5 +57,24 @@
                    throw new Exception($"【{detail.plcdetail_remark}】,DB地址{detail.plcdetail_db + "." + detail.plcdetail_value},未定义数据类型{detail.plcdetail_valtype}");
                }
        }
        /// <summary>
        ///
        /// </summary>
        /// <param name="detail"></param>
        /// <param name="client"></param>
        /// <param name="value"></param>
        /// <returns></returns>
        public static object Write(dt_plcinfodetail detail, PLCClient client, object value)
        {
            try
            {
                return (client.Write(detail.plcdetail_db + "." + detail.plcdetail_value, value));
            }
            catch (Exception ex)
            {
                throw;
            }
        }
    }
}