private ActionResult DownloadReport(ReportFormat format, bool isLocalReport, string filename = null) { if (isLocalReport) { return(this.Report( format, LocalReportName, new { Parameter1 = "Test", Parameter2 = 123 }, ProcessingMode.Local, new Dictionary <string, DataTable> { { "Products", LocalData.GetProducts() }, { "Cities", LocalData.GetCities() } }, filename)); } return(this.Report( format, RemoteReportName, new { Parameter1 = "Hello World!", Parameter2 = DateTime.Now, Parameter3 = 12345, Parameter4 = (DateTime?)null }, filename: filename)); }