public static ArrayList DataSetToArrayList(string Columns, DataTable dataTable)
{
ArrayList output = new ArrayList();
string[] columnName = Columns.Split(',');
foreach (DataColumn row in dataTable.Columns)
{
foreach (string column in columnName)
{
if (column == row.ColumnName)
output.Add(column);
}
}
return output;
}
No comments:
Post a Comment