Server Report Set Parameters method

Last post 05-15-2008, 3:29 AM by hotlips. 0 replies.
Sort Posts: Previous Next
  •  05-15-2008, 3:29 AM Post number 52992

    Server Report Set Parameters method

    Please can anyone HELP....

    Hi I am trying to pass parameters ( startdate and enddate) to a report web page .... the report created using SQL business intelligence development studio with the same parameters.....I wish to pass the parameters from the web page Ajax calendar controls I have set in the web page which are used to pass paremeters to other reports on the page (these not created by business intellegence studio).  I do do not want to use the parameters created in business intelligence studio. 

    My frustration is I get error :- 

    Error 1 'System.Collections.IEnumerable' has no type parameters and so cannot have type arguments.

    This is my code (taken from Microsoft site) :-

    http://msdn.microsoft.com/en-gb/library/microsoft.reporting.webforms.serverreport.setparameters(VS.80).aspx

    Public Overrides Sub setparameters(ByVal params As IEnumerable(Of ReportParameter))

    Dim instance As ServerReport

    Dim params As IEnumerable(Of ReportParameter)

    instance.SetParameters(params)

    End Sub

      

    Dim s As New ReportParameter("startdate", startdate)

    Dim f As New ReportParameter("enddate", enddate)

    ReportViewer1.ServerReport.SetParameters(s)

    ReportViewer1.ServerReport.SetParameters(f)

    '******************************************************************

    Thanks in advance

View as RSS news feed in XML