Ejemplo n.º 1
0
 private void dgLocalAdd_RowHeaderMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
 {
     if (dgLocalAdd.Rows.Count >= 1)
     {
         foreach (DataGridViewRow Row in dgLocalAdd.SelectedRows)
         {
             DataRow RW1 = LocalAddTB.Rows[Row.Index];
             LocalTB.ImportRow(RW1);
             LocalAddTB.Rows.RemoveAt(Row.Index);
         }
     }
 }
Ejemplo n.º 2
0
 private void btnLocal_Click(object sender, EventArgs e)
 {
     LocalCN.ConnectionString = Properties.Settings.Default.LocalCN;
     if (cbLocal.Text != "" && LocalCN.ConnectionString != "")
     {
         LocalTB               = UT.FN_GetTbColumnList(LocalCN, cbLocal.Text);
         LocalBS.DataSource    = LocalTB;
         dgLocal.DataSource    = LocalBS;
         LocalAddTB            = LocalTB.Clone();
         LocalAddBS.DataSource = LocalAddTB;
         dgLocalAdd.DataSource = LocalAddBS;
     }
     else
     {
         MessageBox.Show("لطفا یک جدول را انتخاب نمایید.");
     }
 }