Hello,
I'm having problems using the ReportViewer control (which you can use in VS2005). When I go to the page that contains the control, the images (back, next, print, etc) don't show up and I get different javascript errors (one of them is the "RSClientController is undefined" error). After some investigation, I found out that the path to the Reserved.ReportViewerWebControl.axd file is incorrect (as I see it in the page source). On every place this axd file is used (for the images and the necessary javascript file), the path is "/Reserved.ReportViewerWebControl.axd?...", while it should be "/reportserver/Reserved.ReportViewerWebControl.axd?...". If I go directly to the "/reportserver/..." url, I can retrieve the images and javascript file. So, somewhere the path to the axd file is set in a wrong way.
For example:
<script src="/Reserved.ReportViewerWebControl.axd?OpType=Resource&Version=8.0.50727.42&Name=Scripts.ReportViewer.js" type="text/javascript"></script>
while this should be:
<script src="/ReportServer/Reserved.ReportViewerWebControl.axd?OpType=Resource&Version=8.0.50727.42&Name=Scripts.ReportViewer.js" type="text/javascript"></script>
I have included the ReportViewer control in a usercontrol (ascx). This usercontrol is implemented in Sharepoint using the "Son of Smartpart" webpart. I'm using SQL Reporting Services 2005 (with the database, SQL Server 2005, hosted on another server). Using the ReportManager, everything is fine.
I really need to get this working, but I'm out of ideas (I've been searching for days to solve this, but can't seem to find the correct solution).
Any ideas?
Sven
One ugly hack would be to copy the javascript and images to where it is looking for it... (root)
Did you set the reportserver url in your control?
http://www.devx.com/dotnet/Article/30610/0/page/2
Have you tried using www.sysinternal.com filemon on the web server to determine where it's looking for files and whether there are permission issues?
Here is another thread that mentions a similar issue.
cheers,
Andrew
|||
Hey Andrew,
Thanks for your quick reply.
I'm not sure whether that "ugly hack" would be possible. To be honest, I don't know the exact working of the axd HttpHandler, but I don't think I can modify the ReportViewer control and tell it to get the images from somewhere else. As far as I have understood, the images and javascript file are retrieved from the database, only the axd file (which is generated on the fly again: that is what I've read) is in the wrong location.
The ReportServer url is correctly set in my control.
Sven
|||You may be able to get at these files from your internet cache directory and then place them in the root of the web server, but it doesn't fix the underlying issue.
Also, if you haven't already, try posting in Report Controls forum.
http://forums.microsoft.com/MSDN/ShowForum.aspx?ForumID=75&SiteID=1
Are you using any kind of authentication mechanism, and has the directory been configured as an application? Do you have fixed headers in your report?
cheers,
Andrew
|||Hello Andrew,
I'm not using some special kind of authentication mechanism. Although, I am implementing the Report Viewer (or at least trying to do this) in a Sharepoint application, which has its own security mechanism. The directory is configured as an application (Sharepoint does this for you btw). I don't have any fixed headers in my report, the control fails even when I try to view a very basic (Northwind) report.
It's strange that the path to my axd is wrong, possibly Sharepoint is causing this but at this moment I still don't have any clue.
Sven
|||Hey Sven,
Did you get how to solve your issue, I think I got the same problem.
|||Hey Renan,
Sorry for the late reply. I didn't really solve the problem. Actually, I don't think it can be solved :).
I'm quite sure the problem has something to do with the HttpHandlers. I think that SharePoint overrides the HttpHandler that you set (the famous .axd file), which is why the control doesn't render correctly.
What I did: I created a new web application in a new Virtual Directory (under the root of the SharePoint web app) and created an aspx page that contains the Report Viewer control. I copied the SharePoint toolbar from the HTML source into the aspx page so the user doesn't notice that he's actually in another web app.
Hope this helps.
Sven
sql
No comments:
Post a Comment