public void SetMaxPrice() { ProductArr productArr = new ProductArr(); productArr.Fill(); txt_maxPrice.Text = productArr.MaxPriceBuy().ToString(); }
private void Form_ViewCarForBuy_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F && e.Modifiers == Keys.Control) { this.TopMost = false; ProductArr productArr = new ProductArr(); productArr.Fill(); productArr.Sort(); Form_FilterView newform = new Form_FilterView(productArr.MaxPriceBuy().ToString()); if (newform.ShowDialog() == DialogResult.OK) { this.dgv_Cars.Rows.Clear(); ShowColumns(newform.GetCars()); } this.TopMost = true; } else if (e.KeyCode == Keys.I && e.Modifiers == Keys.Control) { // Show Instructions lbl_Instructions.Visible = isopen; isopen = !isopen; } else if (e.KeyCode == Keys.Escape) { Form_MidView newform = new Form_MidView(newemployee, form); form.OpenForm(newform); } else if (e.KeyCode == Keys.N && e.Modifiers == Keys.Control) { // Form_Home newform = new Form_Home(newemployee, true); Form_Product newform = new Form_Product(newemployee); form.OpenForm(newform); form.MovePanel(form.btn_Product); } }