protected override bool ProcessCmdKey(ref Message msg, Keys keyData) { if (keyData == Keys.Enter) { if (m_level == RewardLevel.Four) { //读取所有合法用户,过滤掉已经获奖的用户 InitUIByLevel(true, false); FrmInput4Level frm = new FrmInput4Level(RewardLevel.Four, m_users, m_exclude); frm.ShowDialog(); return base.ProcessCmdKey(ref msg, keyData); } else { btnStart_Click(null, null); return true; } } else { return base.ProcessCmdKey(ref msg, keyData); } }
如何处理Form 上的键盘事件,ProcessCmdKey肯定起作用!!
最新推荐文章于 2023-07-14 10:06:09 发布