Showing posts with label writen. Show all posts
Showing posts with label writen. Show all posts

Sunday, March 11, 2012

Change URL

Can any body help me i need to chanage my URL when select my TPM and TPK

i have two option in my Filter 1.TPM

2.TPK

i writen some custome code here but its not working i know some thing wrong in that

its my Code here:-

Public Function access(ByVal parameter As Object) As String

IF parameter Is "TPM" Then

Response.Write("<script language=""Javascript"">window.open ('//localhost/Reportserver/Pages/ReportViewer.aspx?%2fTPM%2fAFM1&rs:Command=Render&rc:Toolbar=true&RUNDATE=" & Parameters!TPM.Value & ' ,'mywindow','location=1,status=1,resizable=yes,scrollbars=1,width=400,height=400');</script>")

ElseIF parameter Is "TPK" Then

Response.Write"<scriptlanguage="javapt"">window.open //localhost/Reportserver/Pages/ReportViewer.aspx?%2fTPM%2fTPM01&rs:Command=Render&rc:Toolbar=true&TPK=" & Parameters!TPK.Value & " ','_blank','location=1,status=1,resizable=yes,scrollbars=1,width=400,height=400');</script>")

End If

End Function

Normal Url is working properly actual problem is i want to change URL depends on parameter selection.Custome code is giving some error like

Error: Response is not declared......

when i written custome code i will declare my parameter=code.access(parameter!sao.value) ? Is it Currect?

Can anybody tell me how to do this one because i really struck here only..

Thanking you.

Your code assumes that you are running in the context of an ASPX page. This isn't the case. The Response object is never declared. So the error message is correct.

|||

Wouldn't it be better if u use the reportview control and embed the report in ur aspx page?
Patrick

|||

thanx for your reply

can u give me some example code.Its actually Report Project only i shoudt use aspx pages

where can i change my custom code can u give me some any example

thanx

kiran

|||

Try reading through this website at:-
http://www.gotreportviewer.com/

|||

it ok that site.Its good

But i didt use any aspx pages in my reports i am using only Business intelligece through i developing my reports only i shoudt use aspx pages any where

i am developing only reports only.

in my report Two Filter i need to change my Url dynamically .This is Report1:

Reortid report Name PD KF TK

1 report1 1 0 0

2 report2 2 2 3

3 report3 2 1 0

Actually Here No need to change anydata Here just change my URL only what ever i select that particual option in my filter

in my filter On option is Change Url filter

in two option in TPM and TPK

This Filter is not related to anything data

this filter job is only change the URL sonly.Suppose i will select TPM option it wil come that related URL only.

when i press PD Data it will take hyper like goes to another report ok

i will select TPK option it will change my URL that related URL only.

i am giving one example:

if(value=TPM)

-its going to what ever declare here jump URL

else if (value=TPK)

-its going to what ever declare here jump URL

end

i dont know how to do this task.can any body

thanx