Monthly Archives: January 2015

Fill LINQ data to a data table in C#

Load LINQ data to a variable varlist of data type var. Pass the variable varlist to the below function. public DataTable LINQToDataTable<T>(IEnumerable<T> varlist) { DataTable dtReturn = new DataTable(); //Column names PropertyInfo[] oProps = null; if (varlist == null) return … Continue reading

Posted in C#, Programming | Tagged , , , | Leave a comment