Capturing a sql paramter and display it in the asp.net report
<p>I have a report that displays data based on date range: start date, and end date. These are the parameters fed to the dataset. Is there a way to intercept these parameters and feed them to the report?</p>

<p>Here is my code:</p>

<pre><code>reportViewer1.LocalReport.DataSources.Clear(); 
ReportDataSource rds2 = new ReportDataSource("DataSet1", ods); 
reportViewer1.LocalReport.DataSources.Add(rds2); 
ods.SelectMethod = "GetTransactionByDateRange"; 
ods.TypeName = "ConsumablesTransactionLogBLL"; 

ods.SelectParameters.Add("sd", System.TypeCode.String, dateRange[0]); 
ods.SelectParameters.Add("ed", System.TypeCode.String, dateRange[1]); 
reportViewer1.LocalReport.ReportPath = Server.MapPath("~/Reports/Consumables_By_Range.rdlc");
</code></pre>

<p>Thank you,</p>

<p>Risho</p>
