예제 #1
0
        /// methods
        ///
        private void FillRolesDataGrid()
        {
            dgrid_Roles.DataSource          = null;
            dgrid_Roles.AutoGenerateColumns = false;

            dgrid_Roles.DataSource = _aDRoleWrapper.SelectAll();
            dgrid_Roles.Columns[0].DataPropertyName = "RoleID";
            dgrid_Roles.Columns[2].DataPropertyName = "RoleName";
            foreach (DataGridViewRow row in dgrid_Roles.Rows)
            {
                //DataGridViewCheckBoxCell chk = (DataGridViewCheckBoxCell)dgrid_Roles.Rows[i].Cells["check"];
                //chk.Selected = false;
            }
        }
예제 #2
0
 /// methods
 ///
 private void FillRolesDataGrid()
 {
     try
     {
         dgrid_Roles.DataSource                  = null;
         dgrid_Roles.AutoGenerateColumns         = false;
         dgrid_Roles.DataSource                  = _aDRoleWrapper.SelectAll();
         dgrid_Roles.Columns[0].DataPropertyName = "RoleID";
         dgrid_Roles.Columns[2].DataPropertyName = "RoleName";
     }
     catch (Exception ex)
     {
         MessageBox.Show("حدث خطأ برجاء تكرار العمليه مره اخرى واذا تكرر الخطا برجاءالاتصال بالشخص المصمم للبرنامج وارسال رسالة الخطا التى ستظهر بعد قليل له");
         MessageBox.Show(ex.Message);
     }
 }
예제 #3
0
        /// methods
        ///
        private void FillRolesDataGrid()
        {
            try
            {
                dgrid_Roles.DataSource                  = null;
                dgrid_Roles.AutoGenerateColumns         = false;
                dgrid_Roles.DataSource                  = _aDRoleWrapper.SelectAll();
                dgrid_Roles.Columns[0].DataPropertyName = "RoleID";
                dgrid_Roles.Columns[2].DataPropertyName = "RoleName";
                //foreach (DataGridViewRow row in dgrid_Roles.Rows)
                //{
                //    row.Cells["check"].Value = true;
                //   // chk.Selected = false;

                //}
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }