Link to home
Start Free TrialLog in
Avatar of FIM2003
FIM2003Flag for United States of America

asked on

Missing Parameter Values - Passing to Stored Procedure

I have a report databinded via a stored procedure. I am needing to send an id, begin date and end date. The parameters that the stored procedure has are:

?@id
?@begdate
?@enddate


The report also has several subreports that are each databinded with the stored procedure and then are linked by ?@id.


I am trying to send it via the following code:

report.SetParameterValue("@id", id);
report.SetParameterValue("@begdate", begDateCR);
report.SetParameterValue("@enddate", endDateCR);
 
report.ExportToHttpResponse(ExportFormatType.PortableDocFormat, Response, false, "statement");

Open in new window



However, I am receiving the error:

System.Runtime.InteropServices.COMException: Missing parameter values.

The report looks good and works when I run it within the "Main Report Preview" window and set the values, however, the error at runtime.
ASKER CERTIFIED SOLUTION
Avatar of Chris Bloom
Chris Bloom
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of Mike McCracken
Mike McCracken

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial