///<summary> ///judEigyoushoKeyDown ///コード入力項目でのキー入力判定(営業所) ///</summary> private void judEigyoushoKeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F9) { if (this.Parent is GroupBox || this.Parent is Panel) { EigyoshoList daibunruiList = new EigyoshoList(this.Parent.Parent, this); daibunruiList.Show(); } else { EigyoshoList daibunruiList = new EigyoshoList(this.Parent, this); daibunruiList.Show(); } } else if (e.KeyCode == Keys.Enter) { //TABボタンと同じ効果 SendKeys.Send("{TAB}"); } }
///<summary> ///txtEigyoKeyDown ///コード入力項目でのキー入力判定 ///</summary> private void txtEigyoKeyDown(object sender, KeyEventArgs e) { //営業所リストのインスタンス生成 EigyoshoList eigyoshoList = new EigyoshoList(this); try { //担当者区分リストの表示、画面IDを渡す eigyoshoList.StartPosition = FormStartPosition.Manual; eigyoshoList.intFrmKind = CommonTeisu.FRM_EIGYOSHO; eigyoshoList.Show(); } catch (Exception ex) { //データロギング new CommonException(ex); //例外発生メッセージ(OK) BaseMessageBox basemessagebox = new BaseMessageBox(this, CommonTeisu.TEXT_ERROR, CommonTeisu.LABEL_ERROR_MESSAGE, CommonTeisu.BTN_OK, CommonTeisu.DIAG_ERROR); basemessagebox.ShowDialog(); return; } }