0
votes

I have a SSRS main report in which I am using a subreport. Based on some parameter value I want to show the reports.

For example, I have a parameter called "view" in which I have 2 options:

  1. Detailed view
  2. Overview

When a user selects the "Detalied view" option it should show the subreport Also, when a user selects "Overview" that data comes from the Main Report.

For both the Reports I am using 2 different datasets. The problem is when I run the subreport separately, it works fine. But when I call it from the main Report for some selection criteria, it shows the subreport. But for some other it gives me error that one or more parameter is not supplied to the subreport.

I don't understand the issue. Please any one has any idea please help.

Thanks in advance.

1
If you look at the Parameters page of the subreport properties, can you show us what it says there? - Dan Scally
I bet when you run the sub-report directly you are passing over a required parameter value, however, you are omitting that value in the parameter handshake from main report to sub report. - Ross Bush
i am having same parameters in both the Reports. and also in my sql stored procedue. still i dont get it where m i lacking . - swat
Hi @DanScally i have mapped the Parameters of subreport as well - swat
Hi @DanScally i am not able to post here an image is it not allowed here . or how can i post my report image here - swat

1 Answers

0
votes

I found the solution to my problem: So the problem was hidden in the assignment of the parameters to the subreport. Though i was assigning them corectly but as i had multivalued paramters SSRS itself assigning the value to the paramter with (0) in addidtion. Ex. =Parametrs!ParameterName.Value(0)

i Removed this (0) from end , now my paramter value looks like: ParamterName = [@ParameterName] (Not as some Expression)

and this worked as a charm. :) i answered my question ,so that in case anyone else struggling with the same issue can get a hint.