Example #1
0
 private void  GetConditionTagValue()
 {
     for (int i = 0; i < _conditionList.Count; i++)
     {
         if (_parentDataStoreManager.ReadTagValue(_conditionList[i].ConditionTagName) == null)
         {
             return;
         }
         _conditionList[i].TagValue = float.Parse(_parentDataStoreManager.ReadTagValue(_conditionList[i].ConditionTagName));
     }
 }
        int InsertDataItem(DateTime NowTime)
        {
            string tempFieldValue = "";


            if (_BufferSize > 0)
            {
                tempFieldValue += ",";
            }

            tempFieldValue += "(null,'";
            tempFieldValue += NowTime.ToString("yyyy-MM-dd HH:mm:ss");
            tempFieldValue += "','";

            for (int i = 0; i < _dataStoreConfig.TableInfo.FieldList.Count(); i++)
            {
                DataStoreFieldInfo tempField    = _dataStoreConfig.TableInfo.FieldList[i];
                string             tempTagValue = _parentDataStoreManager.ReadTagValue(tempField.TagName);
                tempFieldValue += tempTagValue + ",";
            }


            tempFieldValue      += "') ";
            _insertDataStoreSql += tempFieldValue;
            _BufferSize++;

            return(0);
        }