public static DataView SelectTopFrom(DataView dv, int rowCount)
{
DataTable dt = dv.ToTable();
DataTable dtn = dt.Clone();
for (int i = 0; i < rowCount; i++)
{
dtn.ImportRow(dt.Rows[i]);
}
DataView dvn = new DataView(dtn);
return dvn;
}
{
DataTable dt = dv.ToTable();
DataTable dtn = dt.Clone();
for (int i = 0; i < rowCount; i++)
{
dtn.ImportRow(dt.Rows[i]);
}
DataView dvn = new DataView(dtn);
return dvn;
}
No comments:
Post a Comment