Hiding Report Parameters

Dear Vivian:

You didn’t leave me a return address, so I hope you see this response. I said I had an answer for you, but it’s taken many days to respond, and I apologize. It has been a difficult week in the salt mines. Deployments. Conference calls. Customers destroying network settings. Sales staff destroying demo software. It's crazy around here.

Anyway, the question was: how to hide a parameter in Reporting Services?

Go to the Report menu, select Report Parameters, and highlight the parameter you need to hide. The key is to clear the Prompt text box, and make sure to supply a default value. Reporting Services will no longer prompt the user to enter a value for the parameter. The parameter value can still be dynamic if there is a VB expression or a query to specify the default value.

To override the parameter at run time with a different value (perhaps by passing the new value in the query string when using URL access), then you may get the error “parameter is readonly and may not be modified”. Make sure to install SP1 for Reporting Services to fix this.

To determine the version of Reporting Services, go to the base URL for the report server (typically http://machinename/reportserver/. At the bottom of the browser page will be the version number:

   Microsoft SQL Server Reporting Services Version 8.00.743.00  <- this is old

   Microsoft SQL Server Reporting Services Version 8.00.878.00  <- this is SP1

Print | posted @ Monday, December 13, 2004 6:19 AM

Comments on this entry:

Gravatar # re: Hiding Report Parameters
by Johan Trusell at 1/21/2005 1:56 AM

Hello,
<br>
<br>I tried this, but RS is still prompting. Is it beacause I have more than one parameter?
<br>
<br>Best regards/ Johan
  
Gravatar # re: Hiding Report Parameters
by Scott at 1/21/2005 4:14 AM

Johan: Do all the parameters have defaults?
  
Gravatar # re: Hiding Report Parameters
by David at 2/1/2005 11:15 PM

I've installed SP1 but I still get a message: &quot;The report parameter '&lt;parameter name&gt;' is read-only and cannot be modified. (rsReadOnlyReportParameter) Get Online Help&quot;. Everything works fine except when I try to set the hidden parameter from the URL. Is there something I'm doing wrong?
<br>
  
Gravatar # re: Hiding Report Parameters
by Scott at 2/3/2005 4:45 AM

Did you happen to clear the &quot;prompt user&quot; checkbox? I believe this has to be checked, but the prompt string has to be empty. Does that help?
  
Gravatar # re: Hiding Report Parameters
by james king at 3/19/2005 10:17 PM

Hi, I would like to hide the parameters as I do not prompt the user for any. Parameters are supplied based on other information relating to a user on a web site. The problem I have is that if I view the source ( the report is a drill down report) the parametes can be viewed. Is there any way to mask the paramters from the source. I tried generating the report thru the SOAP API and based on the sessioned use the sessionID to render the uRL rs:SessionID=.... This also did not work as the parameters, although stored (SessionData table) are not rendered based on the current sessionID.
  
Gravatar # re: Hiding Report Parameters
by Scott at 3/19/2005 11:25 PM

Perhaps you could set the default parameter value to an expression with code in Reporting Services.
  
Gravatar # re: Hiding Report Parameters
by james at 3/20/2005 2:09 AM

If the parametrs are stored on the database along with the sessionID is there no way to force the use of the parameters for that session. I noticed there is also a sanpshotID does the same apply, in that, can I pass in a snapshotID and have the report rendered with the parameters insteading of prompting again?
<br>Are there any appoaches to hiding the parameters source with ReportViewer?
<br>
  
Gravatar # re: Hiding Report Parameters
by Scott at 3/22/2005 5:28 PM

With the ReportViewer you should be able to pass all the parameters in the query string, and set the parameter area visibility to false.
  
Gravatar # re: Hiding Report Parameters
by Darin at 3/22/2005 7:24 PM

Is there a way to set the &quot;Prompt User&quot; checkbox in the report manager programatically?
<br>
<br>Thanks.
  
Gravatar # re: Hiding Report Parameters
by Scott at 3/23/2005 5:24 PM

Darin:
<br>
<br>You can do this with programatically with the SOAP API. SetReportParameters takes an array of ReportParameter objects. A ReportParameter has a PromptUser boolean property.
  
Gravatar # re: Hiding Report Parameters
by Andy at 3/24/2005 6:58 AM

I have linked to a related blog entry. I posted a note under &quot;Andy&quot; for those of you that are trying to hide a userid.
  
Gravatar # re: Hiding Report Parameters
by Andy at 3/24/2005 6:59 AM

oops, the link ended up as my name. I guess that makes sense, but here it is again:
<br>
<br>http://geekswithblogs.net/gobrien/archive/2004/07/30/9116.aspx
  
Gravatar # re: Hiding Report Parameters
by Bob Brutus at 3/31/2005 6:56 PM

The easiest way to hide report Parameters is as follows:
<br> strReportParm = &quot;rc:Parameters=false&quot;
<br> strReportParm +=&quot;OtherParms&quot;
<br>&quot;http://Localhost/ReportManager?/Report Folder/ReportName&quot;, strReportParm
<br>
<br>Have Fun
  
Gravatar # re: Hiding Report Parameters
by Timur at 7/14/2005 12:35 PM

Hello All!
I have a problem with hiding 2 of 3 report parameters. How could I send 2 report parameters in URL and provide user with possibility to select remaining one?

I've tried to realize this, but after selecting remaining parameter and clicking 'View report' I just see nothing, no errors and no report.
  
Gravatar # Making the Default value Dynamic in report parameter
by Valar at 6/28/2006 11:02 AM

Hi all...
Here I have a problem in MSRS2005.
Let me explain my scenario..
I have a report parameter allowed Multivalue selection in it. The value for this parameter is coming from a Dataset, suppose if this dataset returns only one value , the parameter should be defaulted otherwise if it returns more than 1 value the parameter should not be defaulted. Is there any way to achieve this??
I have tried adding a second datset to get the number of rows returned by the first dataset, by passsing this value to the parameter default expression..but this doesnt work. Can anybody help me out in this...

Thanks in Advance
Valar
  
Gravatar # re: Hiding Report Parameters
by Dom at 6/29/2006 8:18 PM

Since this is a popular search result, everyone please note that SP2 is out.

And also that you may have to apply SP2 to the server and to the box running visual studio (can someone confirm this?)
  
Gravatar # re: Hiding Report Parameters
by scott at 6/30/2006 12:47 AM

Valar: I'm afraid I can't help, I have not used SSRS 2005.

Dom: Yes, that is correct. The SP would need to be applied anywhere there is an SSRS component installed, either client or server.
  
Comments have been closed on this topic.