private void msbEmployees_List_Click(object sender, EventArgs e) { var f = new frmEmployees(); f.MdiParent = this; f.Show(); }
private void employeesToolStripMenuItem_Click(object sender, EventArgs e) { Form f = new frmEmployees(); f.MdiParent = this; f.Show(); }
private void barButtonItem12_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) { Form f = IsActive(typeof(frmEmployees)); if (f == null) { Form frmEmployees = new frmEmployees(); frmEmployees.MdiParent = this; frmEmployees.Show(); } else { f.Activate(); } }
private void BtnNhanVien_ItemClick(object sender, ItemClickEventArgs e) { Form f = IsActive(typeof(frmEmployees)); if (f == null) { VaiTro_ChucNangDTO pqnv = btnNhanVien.Tag as VaiTro_ChucNangDTO; frmEmployees frmEmployees = new frmEmployees(pqnv, username); frmEmployees.ThemNhatKyHeThong += ThemNhatKy_Main; frmEmployees.MdiParent = this; frmEmployees.Show(); } else { f.Activate(); } }
private void btnGo_Click(object sender, EventArgs e) { frmEmp.MdiParent = this; frmEmp.Show(); }
private void employeesToolStripMenuItem_Click(object sender, EventArgs e) { frmEmployees employees = new frmEmployees(); employees.Show(); }
private void GenerateContentForClickItems(string formName, bool clickForSearch) { if (formName == VehicleReports) { frmVehiclesReport frm = new frmVehiclesReport(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } if (formName == Branches) { if (clickForSearch) { frmBranch frm = new frmBranch(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateBranch frm = new frmAddUpdateBranch(); frm.Show(); } } if (formName == Clients) { if (clickForSearch) { frmClient frm = new frmClient(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateClient frm = new frmAddUpdateClient(); frm.Show(); } } if (formName == Countries) { if (clickForSearch) { frmCountries frm = new frmCountries(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddCountry frm = new frmAddCountry(); frm.Show(); } } if (formName == Employees) { if (clickForSearch) { frmEmployees frm = new frmEmployees(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateEmployee frm = new frmAddUpdateEmployee(); frm.Show(); } } if (formName == EmployeeRoles) { if (clickForSearch) { frmEmployeeRoles frm = new frmEmployeeRoles(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateEmployeeRoles frm = new frmAddUpdateEmployeeRoles(); frm.Show(); } } if (formName == Insurance) { if (clickForSearch) { frmInsurance frm = new frmInsurance(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateInsurance frm = new frmAddUpdateInsurance(); frm.Show(); } } if (formName == Ratings) { if (clickForSearch) { frmRating frm = new frmRating(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } } if (formName == Reservations) { if (clickForSearch) { frmReservation frm = new frmReservation(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } } if (formName == VehicleCategories) { if (clickForSearch) { frmVehicleCategory frm = new frmVehicleCategory(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVehicleCategory frm = new frmAddUpdateVehicleCategory(); frm.Show(); } } if (formName == Vehicles) { if (clickForSearch) { frmVehicle frm = new frmVehicle(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVehicle frm = new frmAddUpdateVehicle(); frm.Show(); } } if (formName == VehicleFuelTypes) { if (clickForSearch) { frmVehicleFuelType frm = new frmVehicleFuelType(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVFuelType frm = new frmAddUpdateVFuelType(); frm.Show(); } } if (formName == VehicleManufacturers) { if (clickForSearch) { frmVehicleManufacturer frm = new frmVehicleManufacturer(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVehicleManufacturer frm = new frmAddUpdateVehicleManufacturer(); frm.Show(); } } if (formName == VehicleModels) { if (clickForSearch) { frmVehicleModel frm = new frmVehicleModel(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVehicleModel frm = new frmAddUpdateVehicleModel(); frm.Show(); } } if (formName == VehicleTransmissionTypes) { if (clickForSearch) { frmVehicleTransmissionType frm = new frmVehicleTransmissionType(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVehicleTransmissionType frm = new frmAddUpdateVehicleTransmissionType(); frm.Show(); } } if (formName == VehicleTypes) { if (clickForSearch) { frmVehicleType frm = new frmVehicleType(); frm.MdiParent = this; frm.WindowState = FormWindowState.Maximized; frm.Show(); } else { frmAddUpdateVehicleType frm = new frmAddUpdateVehicleType(); frm.Show(); } } }