public Form_MidView(Employee emplooye, Form_Home f1) { InitializeComponent(); form = f1; newemployee = emplooye.CreateEmployee(); }
public Form_MidOrder(Employee employee, Form_Home f1) { InitializeComponent(); panel3 = f1.pnl_Background; form = f1; newemployee = employee.CreateEmployee(); }
private void btn_Admin_Click(object sender, EventArgs e) { string Username = "******", Password = "******"; if (CheckEmployee(Username, Password)) { Form_Home newform = new Form_Home(GetEmployee(Username, Encrypt(Password))); Hide(); newform.ShowDialog(); Close(); } else { MessageBox.Show("The Username or the password don't match", "Error", MessageBoxButtons.OKCancel, MessageBoxIcon.Error); } }
public Form_ViewCarForBuy(Employee employee, Form_Home f1) { InitializeComponent(); newemployee = employee.CreateEmployee(); this.FormBorderStyle = FormBorderStyle.None; // מסתיר את האופיציה של האיקס כדי לצאת /// this.Bounds = Screen.PrimaryScreen.Bounds; this.Dock = DockStyle.Fill; form = f1; lbl_Instructions.Left = (this.Width / 2) - (lbl_Instructions.Width / 2); lbl_Instructions.Top = (this.Height / 2) - (lbl_Instructions.Height / 2); lbl_Instructions.Visible = false; CarArrToForm(); UpdateStyle(); dgv_Cars.BackgroundColor = Color.FromArgb(41, 44, 51); }
private void btn_LogIn_Click(object sender, EventArgs e) { if (CheckForm()) { if (CheckEmployee(txt_Username.Text, txt_Password.Text)) { //Form_HomePage newform = new Form_HomePage(GetEmployee(txt_Username.Text, Encrypt(txt_Password.Text))); //Hide(); //newform.ShowDialog(); //Close(); Form_Home newform = new Form_Home(GetEmployee(txt_Username.Text, Encrypt(txt_Password.Text))); Hide(); newform.ShowDialog(); Close(); } else { MessageBox.Show("The Username or the password doesn't match", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } } }