I want to convert my Model data to DataSet
or DataTable
(to export in excel format)
db.EMPs.ToList()
db
is DataContext
, EMPs
is dataclass
.
How to export this list to DataTable
, I can export rows to excel but how to access column name from header (column name should not be added manually in DataTable
)
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…