示例#1
0
        private void dgvData_CellDoubleClick(object sender, GridViewCellEventArgs e)
        {
            try

            {
                if (screen.Equals(1))
                {
                    RCNo_tt.Text = Convert.ToString(e.Row.Cells["RCNo"].Value);
                    this.Close();
                }
                else

                {
                    ClearTemp a = new ClearTemp(Convert.ToString(e.Row.Cells["RCNo"].Value));
                    a.ShowDialog();
                }
            }
            catch { }
        }
示例#2
0
 private void btnSave_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
         {
             ClearTemp a = new ClearTemp(Convert.ToString(dgvData.CurrentRow.Cells["RCNo"].Value));
             a.ShowDialog();
         }
     }
     catch (Exception ex) { MessageBox.Show(ex.Message); }
 }