I wont be able to bind datatable, to report it is giving error as object reference if just set datatable to asenummarable and assign.
The code I am using is given below, please tell me where I am wrong
#region modifiedcode
SqlConnection conn = new SqlConnection("");
;
#endregion
var contributors = new ContributorsList().SmallContributorCollection;
var reportDefinitionAsStream = LoadStreamFromResource("ErrorList.srd");
var rf = new ReportingFactory();
var reportCreator = rf.ReportCreator(reportDefinitionAsStream, runQuery("SELECT Top 10 * FROM ELMAH_error", conn).AsEnumerable());
reportCreator.BuildExportList();
var ms = new MemoryStream();
PdfExporter ex = new PdfExporter(reportCreator.Pages);
ex.Run(ms);
ms.Seek(0, SeekOrigin.Begin);
return File(ms, "application/pdf", "contributors.pdf");