Saturday, February 11, 2012

* * * Passing Parameter - Urgent * * *

I program an ASP.NET application that uses SQL Server 2005 Reporting
Services.
Recently I came into a dead end when I had to pass a parameter from my
application
to the report. I 've looked over the Internet and found absolutely nothing.
If someone is
capable of doing that he/she doesn't have to be shy to share it with me.
Thanks in advance,
Nick Hatzis
P.S. : To answer by e-mail remove the "bog" from the username.Hi,
What kind of parameter you must pass?|||Hi Cesar,
I have to pass four string parameters.
Two that will appear in the report and two
(from-to) that will be used in the query.
Thanks in advance,
Nick Hatzis
P.S. : To answer by e-mail remove the "bog" from the username.
"Cesar" <Cesar@.discussions.microsoft.com> wrote in message
news:490E74EF-519C-4D5E-BB69-C8412CB909C2@.microsoft.com...
> Hi,
> What kind of parameter you must pass?|||Are you using an URL to open the report? In that case, you should look at
the topic "URL access" in the SQL Server 2005 Books Online.
If you have it locally, this should be the URL
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/rptsprg9/html/52c3f2a3-3d6d-4fee-9c46-83f366919398.htm
Or find it online at
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/rsprog/htm/rsp_prog_urlaccess_374y.asp
Kaisa M. Lindahl Lervik
"Nick Hatzis" <boghatzisn@.panafonet.gr> wrote in message
news:%23MK70oQ7GHA.1012@.TK2MSFTNGP05.phx.gbl...
>I program an ASP.NET application that uses SQL Server 2005 Reporting
> Services.
> Recently I came into a dead end when I had to pass a parameter from my
> application
> to the report. I 've looked over the Internet and found absolutely
> nothing.
> If someone is
> capable of doing that he/she doesn't have to be shy to share it with me.
> Thanks in advance,
> Nick Hatzis
> P.S. : To answer by e-mail remove the "bog" from the username.
>|||On Wed, 11 Oct 2006 11:01:52 +0300, "Nick Hatzis"
<boghatzisn@.panafonet.gr> wrote:
>I program an ASP.NET application that uses SQL Server 2005 Reporting
>Services.
>Recently I came into a dead end when I had to pass a parameter from my
>application
>to the report. I 've looked over the Internet and found absolutely nothing.
>If someone is
>capable of doing that he/she doesn't have to be shy to share it with me.
>Thanks in advance,
>Nick Hatzis
>P.S. : To answer by e-mail remove the "bog" from the username.
>
Are you using reportviewer or just going direct to the URL? If direct
to the URL, something like this:
Response.Redirect("http://199.199.199.199/ReportServer?%2fReportProjectName%2fReportName&rs:Command=Render&rs:Format=PDF&IssueID=11000")
That IssueID at the end is a parameter. Note the rs:Format that gets
the report directly as a PDF.
If you're using a reportviewer control, parameters are done like this:
Dim RptParm As New
Microsoft.Reporting.WebForms.ReportParameter("FileNumParam",
lblFileNum.Text) ' name/value pair for a parameter
Dim RptParms As New Generic.List(Of
Microsoft.Reporting.WebForms.ReportParameter)
RptParms.Add(RptParm)
' add more parameters as necessary to RptParams
Reportviewer1.ServerReport.SetParameters(RptParms)

No comments:

Post a Comment