Пример #1
0
 private void btnSave_Click(object sender, EventArgs e)
 {
     try
     {
         if (screen.Equals(1))
         {
             if (!Convert.ToString(dgvData.CurrentRow.Cells["ADNo"].Value).Equals(""))
             {
                 ADNo_tt.Text = Convert.ToString(dgvData.CurrentRow.Cells["ADNo"].Value);
                 this.Close();
             }
             else
             {
                 ADNo_tt.Text   = Convert.ToString(dgvData.CurrentRow.Cells["ADNo"].Value);
                 CodeNo_tt.Text = Convert.ToString(dgvData.CurrentRow.Cells["CodeNo"].Value);
                 this.Close();
             }
         }
         else
         {
             AdjustStock a = new AdjustStock(Convert.ToString(dgvData.CurrentRow.Cells["ADNo"].Value),
                                             Convert.ToString(dgvData.CurrentRow.Cells["CodeNo"].Value));
             a.ShowDialog();
             //this.Close();
         }
     }
     catch (Exception ex) { MessageBox.Show(ex.Message); }
 }
Пример #2
0
 private void dgvData_CellDoubleClick(object sender, Telerik.WinControls.UI.GridViewCellEventArgs e)
 {
     //if (screen.Equals(1))
     //{
     //    if (!Convert.ToString(e.Row.Cells["RCNo"].Value).Equals(""))
     //    {
     //        RCNo_tt.Text = Convert.ToString(e.Row.Cells["RCNo"].Value);
     //        this.Close();
     //    }
     //    else
     //    {
     //        RCNo_tt.Text = Convert.ToString(e.Row.Cells["RCNo"].Value);
     //        PRNo_tt.Text = Convert.ToString(e.Row.Cells["PRNo"].Value);
     //        this.Close();
     //    }
     //}
     //else
     try
     {
         {
             AdjustStock a = new AdjustStock("",
                                             Convert.ToString(e.Row.Cells["CodeNo"].Value));
             a.ShowDialog();
             //this.Close();
         }
     }
     catch (Exception ex) { MessageBox.Show(ex.Message); }
 }
Пример #3
0
 private void MasterTemplate_CellDoubleClick(object sender, GridViewCellEventArgs e)
 {
     try
     {
         if (e.RowIndex > 0)
         {
             if (screen.Equals(1))
             {
                 if (!Convert.ToString(e.Row.Cells["ADNo"].Value).Equals(""))
                 {
                     ADNo_tt.Text = Convert.ToString(e.Row.Cells["ADNo"].Value);
                     this.Close();
                 }
                 else
                 {
                     ADNo_tt.Text   = Convert.ToString(e.Row.Cells["ADNo"].Value);
                     CodeNo_tt.Text = Convert.ToString(e.Row.Cells["CodeNo"].Value);
                     this.Close();
                 }
             }
             else
             {
                 AdjustStock a = new AdjustStock(Convert.ToString(e.Row.Cells["ADNo"].Value),
                                                 Convert.ToString(e.Row.Cells["CodeNo"].Value)
                                                 , this.Name);
                 a.ShowDialog();
                 //this.Close();
             }
         }
     }catch (Exception ex) { MessageBox.Show(ex.Message); }
 }
Пример #4
0
 private void radButtonElement1_Click(object sender, EventArgs e)
 {
     try
     {
         //if (screen.Equals(1))
         //{
         //    if (!Convert.ToString(dgvData.CurrentRow.Cells["RCNo"].Value).Equals(""))
         //    {
         //        RCNo_tt.Text = Convert.ToString(dgvData.CurrentRow.Cells["RCNo"].Value);
         //        this.Close();
         //    }
         //    else
         //    {
         //        RCNo_tt.Text = Convert.ToString(dgvData.CurrentRow.Cells["RCNo"].Value);
         //        PRNo_tt.Text = Convert.ToString(dgvData.CurrentRow.Cells["PRNo"].Value);
         //        this.Close();
         //    }
         //}
         //else
         {
             AdjustStock a = new AdjustStock("",
                                             Convert.ToString(dgvData.CurrentRow.Cells["CodeNo"].Value));
             a.ShowDialog();
             //this.Close();
         }
     }
     catch (Exception ex) { MessageBox.Show(ex.Message); }
 }
Пример #5
0
 private void MasterTemplate_CellDoubleClick(object sender, GridViewCellEventArgs e)
 {
     if (screen.Equals(1))
     {
         if (!Convert.ToString(e.Row.Cells["ADNo"].Value).Equals(""))
         {
             ADNo_tt.Text = Convert.ToString(e.Row.Cells["ADNo"].Value);
             this.Close();
         }
         else
         {
             ADNo_tt.Text   = Convert.ToString(e.Row.Cells["ADNo"].Value);
             CodeNo_tt.Text = Convert.ToString(e.Row.Cells["CodeNo"].Value);
             this.Close();
         }
     }
     else
     {
         AdjustStock a = new AdjustStock(Convert.ToString(e.Row.Cells["ADNo"].Value),
                                         Convert.ToString(e.Row.Cells["CodeNo"].Value));
         a.ShowDialog();
         //this.Close();
     }
 }