Пример #1
0
 /// <summary>
 /// 初始化数据
 /// </summary>
 public void InitData() {
     if (this.Site!=null &&this.Site.DesignMode) return;//必要的,否则设计时可能会报错
     //需要初始化数据时在这写代码
     IList<E_ExamSet> list = MainHelper.PlatformSqlMap.GetList<E_ExamSet>(" where Code='yxnum'");
     if (list.Count==0)
     {
         E_ExamSet eset = new E_ExamSet();
         eset.Code = "yxnum";
         eset.Value = 80;
         eset.Title = "优秀分数";
         MainHelper.PlatformSqlMap.Create<E_ExamSet>(eset);
     }
     RefreshData("  order by CreateTime desc");
 }
Пример #2
0
 private void gridView1_GotFocus(object sender, EventArgs e)
 {
     if (gridView1.GetFocusedRow()!=null)
     {
         ParentObj = gridView1.GetFocusedRow() as E_ExamSet;
     }
 }
Пример #3
0
        /// <summary>
        /// 新建对象设置Key值
        /// </summary>
        /// <param name="newobj"></param>
        void gridViewOperation_CreatingObjectEvent(E_ExamSet newobj) {
          

        }