예제 #1
0
 private void CallOrderInfo(string sendDate, long orderNumber, string isFwAfterClose)
 {
     try
     {
         if (this._viewType == 1)
         {
             if (this._viewOrderInfo == null)
             {
                 if (this.showOnMainForm)
                 {
                     this._viewOrderInfo = new frmViewOrderInfo(false, sendDate, orderNumber, base.Parent.Top + base.Top + base.Height, isFwAfterClose);
                 }
                 else
                 {
                     this._viewOrderInfo = new frmViewOrderInfo(false, sendDate, orderNumber, 0, isFwAfterClose);
                 }
                 this._viewOrderInfo.FormClosed -= new FormClosedEventHandler(this.viewOrderInfo_FormClosed);
                 this._viewOrderInfo.FormClosed += new FormClosedEventHandler(this.viewOrderInfo_FormClosed);
                 this._viewOrderInfo.TopLevel = false;
                 if (base.Parent.GetType().BaseType == typeof(ClientBaseForm))
                 {
                     this._viewOrderInfo.Parent = base.Parent;
                 }
                 else
                 {
                     this._viewOrderInfo.Parent = base.Parent.Parent;
                 }
                 this._viewOrderInfo.Font = Settings.Default.Default_Font;
                 this._viewOrderInfo.Show();
                 this._viewOrderInfo.BringToFront();
                 this._viewOrderInfo.Focus();
             }
             else
             {
                 this._viewOrderInfo.Initial(sendDate, orderNumber, isFwAfterClose);
                 this._viewOrderInfo.Show();
                 this._viewOrderInfo.BringToFront();
             }
         }
     }
     catch (Exception ex)
     {
         this.ShowError("CallOrderInfo", ex);
     }
 }
예제 #2
0
 public void CloseViewOrderInfoBox()
 {
     try
     {
         if (this._viewOrderInfo != null)
         {
             this._viewOrderInfo.Close();
             this._viewOrderInfo = null;
         }
         if (this.frmConfirm != null)
         {
             this.frmConfirm.FormClosing -= new FormClosingEventHandler(this.frmConfirm_FormClosing);
             if (!this.frmConfirm.IsDisposed)
             {
                 this.frmConfirm.Dispose();
             }
             this.frmConfirm = null;
         }
     }
     catch (Exception ex)
     {
         this.ShowError("CloseViewOrderInfoBox", ex);
     }
 }
예제 #3
0
 public void DisposeMe()
 {
     try
     {
         if (this._viewOrderInfo != null)
         {
             this._viewOrderInfo.FormClosed -= new FormClosedEventHandler(this.viewOrderInfo_FormClosed);
             this._viewOrderInfo.Close();
             this._viewOrderInfo = null;
         }
         if (this._viewOrderInfoTfex != null)
         {
             this._viewOrderInfoTfex.FormClosed += new FormClosedEventHandler(this.viewOrderInfoTfex_FormClosed);
             this._viewOrderInfoTfex.Close();
             this._viewOrderInfoTfex = null;
         }
         this.bgwViewOrder = null;
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
예제 #4
0
 private void viewOrderInfo_FormClosed(object sender, FormClosedEventArgs e)
 {
     try
     {
         this._viewOrderInfo.FormClosed -= new FormClosedEventHandler(this.viewOrderInfo_FormClosed);
         this._viewOrderInfo = null;
         if (this.tmTest == null)
         {
             this.tmTest = new System.Windows.Forms.Timer();
             this.tmTest.Interval = 100;
             this.tmTest.Tick += new EventHandler(this.tmTest_Tick);
         }
         this.tmTest.Stop();
         this.tmTest.Start();
     }
     catch (Exception ex)
     {
         this.ShowError("viewOrderInfo_FormClosed", ex);
     }
 }