Пример #1
0
 private void FrmRoleDlg_Load(object sender, EventArgs e)
 {
     this.Cursor = Cursors.WaitCursor;
     try
     {
         UserRoleTree functionTree = new UserRoleTree(this.systemtree);
         functionTree.ShowFunctionTree();
         //保存表格默认样式
         WindDataManager.SaveDefaltGridViewLayout(TCOM_ROLEgridView, this.Name);
         //恢复表格样式
         WindDataManager.RestoreGridViewLayout(TCOM_ROLEgridView, this.Name);
         //保存默认布局样式
         WindDataManager.SaveDefaltControlLayout(layoutControl1, this.Name);
         //恢复布局样式
         WindDataManager.RestoreControlLayout(layoutControl1, this.Name);
     }
     catch (Exception ex)
     {
         UserMessages.ShowInfoBox(ex.Message);
     }
     finally
     {
         this.Cursor = Cursors.Default;
     }
 }
Пример #2
0
        /// <summary>
        /// 窗体加载事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void TigerForm_Load(object sender, EventArgs e)
        {
            try
            {
                this.Cursor = Cursors.WaitCursor;


                m_DepartmentTree = new DepartmentTree(DepartmentTree);
                m_DepartmentTree.ShowTree();
                AddDepartmentItem     = new ToolStripMenuItem("添加根部门");
                LookCurrentDepartment = new ToolStripMenuItem("查看当前部门");
                ContextMenuStrip DepartmentMenu = m_DepartmentTree.FTreeView.ContextMenuStrip;
                AddDepartmentItem.Click     += new EventHandler(AddDepartmentItem_Click);
                LookCurrentDepartment.Click += new EventHandler(LookCurrentDepartment_Click);
                //保存表格默认样式
                WindDataManager.SaveDefaltGridViewLayout(gridView1, this.Name);
                //恢复表格样式
                WindDataManager.RestoreGridViewLayout(gridView1, this.Name);
                //保存默认布局样式
                //WindDataManager.SaveDefaltControlLayout(layoutControl1, this.Name);
                //恢复布局样式
                //WindDataManager.RestoreControlLayout(layoutControl1, this.Name);
            }
            catch (Exception ex)
            {
                UserMessages.ShowErrorBox(ex.Message);
            }
            finally
            {
                this.Cursor = Cursors.Default;
            }
        }
Пример #3
0
        /// <summary>
        /// 窗体加载事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void TigerForm_Load(object sender, EventArgs e)
        {
            this.Cursor = Cursors.WaitCursor;
            try
            {
                //设置数据源

                m_UserTree = new EmployeeTree(UserTree);
                //显示用户树
                m_UserTree.ShowTree();


                //保存表格默认样式
                WindDataManager.SaveDefaltGridViewLayout(gridView2, this.Name);
                //恢复表格样式
                WindDataManager.RestoreGridViewLayout(gridView2, this.Name);
                //保存默认布局样式
                WindDataManager.SaveDefaltControlLayout(layoutControl1, this.Name);
                //恢复布局样式
                WindDataManager.RestoreControlLayout(layoutControl1, this.Name);
            }
            catch (Exception ex)
            {
                UserMessages.ShowErrorBox(ex.Message);
            }
            finally
            {
                this.Cursor = Cursors.Default;
            }
        }
Пример #4
0
        /// <summary>
        /// 窗体加载事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void TigerForm_Load(object sender, EventArgs e)
        {
            try
            {
                this.Cursor = Cursors.WaitCursor;
                //AllowDelete = false;
                //设置数据源

                m_employeeTree = new EmployeeTree(tvEmployee);
                //显示树
                m_employeeTree.ShowTreeByImg();
                //加载列表信息
                LoadFromInfo();
                dstEmployee.TCOM_USER.EMPLOYEETYPEColumn.DefaultValue = "正式";
                dstEmployee.TCOM_USER.ENABLEColumn.DefaultValue       = true;
                //保存表格默认样式
                WindDataManager.SaveDefaltGridViewLayout(gdvEmployee, this.Name);
                //恢复表格样式
                WindDataManager.RestoreGridViewLayout(gdvEmployee, this.Name);
                //保存默认布局样式
                WindDataManager.SaveDefaltControlLayout(layoutControl1, this.Name);
                //恢复布局样式
                WindDataManager.RestoreControlLayout(layoutControl1, this.Name);
                dstTCONF_WORD.FillDevComboBox("薪资类型", WorkTypeComboBox);
                dstTCONF_WORD.FillDevComboBox("员工类型", EMPLOYEETYPEComboBox);
                dstEmployee.GetAllData();
                dstEmployee.GetAllUserName();
            }
            catch (Exception ex)
            {
                UserMessages.ShowErrorBox(ex.Message);
            }
            finally
            {
                this.Cursor = Cursors.Default;
            }
        }