I'm coding up a WinForm using SSRS WebServices, and I have found I can't see a Hidden property for the ReportParameter
Anyone know how to read if a Parameter is hidden?
You can know that whether the report parameter is hidden or not by using the below code snippets.Dim pAs Microsoft.Reporting.WebForms.ReportParameterInfoFor Each pIn ReportViewer1.ServerReport.GetParametersIf p.Visible =False Then'Parameter is hiddenEnd IfNext|||
Thanks for the reply, but I'm having a little difficulity understanding why this is not available from Reporting Services Web Service.
I am looking up the details from reportservice.asmx WebService, and returning the information back to a List:
CatalogItem[] items =this.objRS.ListChildren(currentFolder,false);(Sorry it's in C#)
Where objRS is the RS WebServices.
Then I use
reportParametersArray =this.objRS.GetReportParameters(report, historyID, forRendering,null,null);
foreach (ReportParameter pin reportParametersArray){
p.Visible; // This odes not exist :-(
}
However Visible is not available using it in this way :-(
Why is it different, and what am I missing?
|||
Hi,
You can get the visibility by adding a condition to the code you have written. Please find the code below. I hope this would help.
--
reportParametersArray =this.objRS.GetReportParameters(report, historyID, forRendering,null,null);
foreach (ReportParameter pin reportParametersArray){
if (p.Prompt =="") {
//Parameter is hidden }}
--
|||Perfect, thanks.
Why oh why the name change from Visible to Prompt?
|||It's something like a flag used for an internal manipulation.
No comments:
Post a Comment