locked
Filters in Sql Server Reporting services. RRS feed

  • Question

  • Hi

    I am using Reporting services 2005 and .net 2.0

    my question is that i want to use the filters dynamically from c#.

     

    1)once the report gets generated ,I want to customize the data using some filters.

    for that i need to acess the filters dnyamically.

    if there is any other way suggest me

    Thanks in advance.

     

    Tuesday, January 27, 2009 9:53 AM

Answers

  •  

    Hi,

     Report Viewer control is only a container in Visual Studio. To processing data for report are depending on report server and your customized dataset. You can check more information from the following link.

    ReportViewer Controls (Visual Studio) 

    http://msdn.microsoft.com/en-us/library/ms251671(VS.80).aspx

    For your issue, you should consider how to query data and format data. So, the first method is using parameter to get data expected. The second method is using local report and customized dataset as report data source.

    Hope this helps.


    Garsy Liang - MSFT
    Monday, February 2, 2009 6:18 AM

All replies

  •  

    You could use Report Viewer control for this. Refer the following MSDN page for detailed info on using Report Viewer control – http://msdn.microsoft.com/en-us/library/ms251671(VS.80).aspx

    Using SetParameters() function (<RepotrViewerobject>.ServerReport.SetParameters()) you should be able to set the report parameter dynamically in the web page.

    Hope this helps.


    ..hegde
    Tuesday, January 27, 2009 10:42 AM
    Answerer
  • Hi Hegde

    My Problem is not with parameters ,

    My question is how can we use filtering option dynamically.

    For Example:

    1)We will populate the data in the Report.

    2)then we will customize the data in the report,say like i want to see only selected data in the report that

    is already populated etc.

    3) for this i need to use dynamic filters.

    I hope i gave you the detailed info

    Hoping for a reply

    Thanks

    CNU  

    Friday, January 30, 2009 7:34 AM
  • I feel the following code bolock will answer your question:

     

    ReportViewer1.ServerReport.ReportServerUrl = reportServerUri;

    ReportViewer1.ServerReport.ReportPath = "/US_IFS/Utilization_SA";

    ReportViewer1.ServerReport.SetParameters(new ReportParameter[] { prmProjectID, prmUtilizationMetricsID });

     

    You van pass all the filter data through prmProjectID, prmUtilizationMetricsID .Lets check and let me know.

     

    Sandip 

     

    • Proposed as answer by San4u Friday, January 30, 2009 8:58 AM
    Friday, January 30, 2009 8:57 AM
  •  

    Hi,

     Report Viewer control is only a container in Visual Studio. To processing data for report are depending on report server and your customized dataset. You can check more information from the following link.

    ReportViewer Controls (Visual Studio) 

    http://msdn.microsoft.com/en-us/library/ms251671(VS.80).aspx

    For your issue, you should consider how to query data and format data. So, the first method is using parameter to get data expected. The second method is using local report and customized dataset as report data source.

    Hope this helps.


    Garsy Liang - MSFT
    Monday, February 2, 2009 6:18 AM