예제 #1
0
 /// <summary>
 /// 폼종료될때
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="System.Windows.Forms.FormClosingEventArgs"/> instance containing the event data.</param>
 private void JNAAI02_FormClosing(object sender, FormClosingEventArgs e)
 {
     try
     {
         if (em != null)
         {
             em.Dispose();
         }
         em = null;
     }
     catch (Exception ex)
     {
     }
     finally
     {
         IsProcess = true;
     }
 }
예제 #2
0
        /// <summary>
        /// 폼로드
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
        private void JNAAI02_Load(object sender, EventArgs e)
        {
            try
            {
                //CR100EM
                //this.txtMsg.Text = "";
                em            = new mRFID.mRF(int.Parse(LockerPort));
                em.IsPoolings = true;

                switch (Parm.CurrentUserInformation.BizInfo.BizCode)
                {
                case "20":
                    em.rfKind = mRF.RFKind.CR100EM;
                    break;

                case "22":
                    em.rfKind = mRF.RFKind.CR100EM;
                    break;

                default:
                    Basic.ShowMessage(1, "락카모듈이 정의되지 않았습니다.");
                    this.timer_Close.Enabled = true;
                    return;
                }


                em.Event_Received += new mRF.Recevied_EventHandler(em_Event_Received);
                em.Open();
                IsProcess = true;
            }
            catch (Exception ex)
            {
                Basic.ShowMessage(3, ex.Message);
                this.timer_Close.Enabled = true;
            }
        }