user1176058
user1176058

Reputation: 676

passing the selected parameter value from ssrs report to asp.net

I need to get the selected value of a parameter and use it in my code. Is there any events where I can capture the parameter values. Please let me know

Upvotes: 0

Views: 1305

Answers (1)

Ann L.
Ann L.

Reputation: 13965

It looks as if the answer is yes.

There's an event on the ReportViewer web control called SubmittingParameterValues that you can handle in the host page. This has a ReportParametersEventArgs parameter, which in turn has a Parameters property.

The Parameters property is a collection of ReportParameter objects. The ReportParameter class has Name and Values properties.

You can use the Name property to find the parameter you're interested in. The Values property, which is a collection of strings, should contain the value submitted.

Upvotes: 1

Related Questions