How to pass credentials when accessing SSRS report through URL

bammeh

New Member
I am trying to access a SSRS report using URL like below\[code\]http://MyServerIP/ReportServer?/FolderName/ReportName&Param1=ParamValue&rs:Command=Render&rs:Format=HTML4.0&rc:Toolbar=false\[/code\]When I try to access above Url, I am asked for my network credentials, giving which I get all pages of SSRS report rendered in browser window. Now I want to display these contents in a popup window inside my webApp. For this I tried to make a jquery request and get contents, but doing this I get 401 unauthorized error. So I wanna know if there is a way to send credentials in jquery ajax get request.As a turnaround I tried using below C# code to retrieve data, but it didn't helped either and gave same 401 error \[code\]WebClient client = new WebClient();client.Credentials = new NetworkCredential("username", "password", "domain");divContents.InnerText = client.DownloadString(my report path);\[/code\]I am using SSRS 2008 R2 and my requirement is to show all pages of report in popup window. So all pointers in this direction are welcome.Adding a point at last, my web app and report may or may not reside on same domain.Thanks,Ravi
 
Back
Top