Esempio n. 1
0
        /// <summary>
        /// Dictionaries the refresh.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        /// <returns></returns>
        protected void DictRefresh(object sender, StoreRefreshDataEventArgs e)
        {
            DataTable data = tgsPproperty.GetEndStationDict(this.CmbStartStation.SelectedItem.Value);

            StoreEndStationDict.DataSource = data;
            StoreEndStationDict.DataBind();
        }
Esempio n. 2
0
 /// <summary>
 /// 获取结束卡口数据(添加、修改位置)
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 protected void DictRefresh(object sender, StoreRefreshDataEventArgs e)
 {
     try
     {
         if (Session["dataTable"] != null)
         {
             DataTable            table = (DataTable)Session["dataTable"];
             System.Data.DataView dv    = new System.Data.DataView(table);
             dv.RowFilter = "col1=" + this.CmbStartStation.SelectedItem.Value;
             DataTable     dt  = dv.ToTable(true, new string[] { "col2" });
             StringBuilder str = new StringBuilder(this.CmbStartStation.SelectedItem.Value);
             for (int i = 0; i < dt.Rows.Count; i++)
             {
                 str.Append("," + dt.Rows[i][0].ToString());
             }
             StoreEndStationDict.DataSource = tgsPproperty.GetEndStationDict(str.ToString());
             StoreEndStationDict.DataBind();
         }
     }
     catch (Exception ex)
     {
         ILog.WriteErrorLog(ex);
         logManager.InsertLogError("PeccancyAreaSetting.aspx-DictRefresh", ex.Message + ";" + ex.StackTrace, "DictRefresh has an exception");
     }
 }