示例#1
0
 private void btnSetOrdinal_Click(object sender, EventArgs e)
 {
     //把第二位的列移前
     mdc.SetOrdinal(mdc[1].ColumnName, 0);
     if (mdc.Table != null && mdc.Table.Rows.Count > 1)
     {
         new MDataTable().Bind(dgvData);
         MDataTable dt = mdc.Table.Clone();
         dt.Bind(dgvData);
     }
     else
     {
         mdc.ToTable().Bind(dgvData);
     }
 }