//快捷键,必要时屏蔽 则无权限 private void MainForm_KeyDown(object sender, KeyEventArgs e) { try { if (qian) { if (e.KeyCode == Keys.F1) { AddHouse ah = new AddHouse(); ah.ShowDialog(); } if (e.KeyCode == Keys.F2) { GroupAddHouseForm GroupAddHouseFrm = new GroupAddHouseForm(); GroupAddHouseFrm.ShowDialog(); } if (e.KeyCode == Keys.F3) { txtFind.Focus(); txtFind.SelectAll(); } if (e.KeyCode == Keys.F6) { SwapHouseForm SwapHouseFrm = new SwapHouseForm(); SwapHouseFrm.ShowDialog(); } if (e.KeyCode == Keys.F7) { JoinHouseForm JoinHosueFormFrm = new JoinHouseForm(); JoinHosueFormFrm.ShowDialog(); } } if (yuding) { if (e.KeyCode == Keys.F8) { BookHouse BookHouseFrm = new BookHouse(); BookHouseFrm.ShowDialog(); } if (e.KeyCode == Keys.F9) { BookInfall BookInfallfrm = new BookInfall(); BookInfallfrm.ShowDialog(); } if (e.KeyCode == Keys.F10) { RescindForm RescinFrm = new RescindForm(); RescinFrm.ShowDialog(); } } if (shouyin) { if (e.KeyCode == Keys.F4) { CashierForm cashierFrm = new CashierForm(); cashierFrm.ShowDialog(); } } if (jinben) { if (e.KeyCode == Keys.F11) { BusinessForm bf = new BusinessForm(); bf.ShowDialog(); } if (e.KeyCode == Keys.F12) { Member m = new Member(); m.ShowDialog(); } } if (e.KeyCode == Keys.F5) { hh.ShowHouseState(index); ShowPrice(); ShowAllInfo(); ShowServer(0); } } catch (Exception ex) { //MessageBox.Show(ex.Message); MessageBox.Show("如快捷键无效!则是您没有权限!", "温馨提示", MessageBoxButtons.OK, MessageBoxIcon.Information); } finally { } }
//预订入住 private void btnBookInfall_Click(object sender, EventArgs e) { BookInfall BookInfallfrm = new BookInfall(); BookInfallfrm.ShowDialog(); }