I have crystal report 2010 installed with VS 2010.i have created a crystal report which is works fine in the localhost but the issue is once i publish my website to IIS the
In my Case I just updated SAP crystal reports Runtime Engine for .NET through Apps and features , I was using crystal report version 18 in my development server , when I deployed the App to another server ,I got this error , then I checked the version I did not get the version , only I got installed date , so I updated to last Version ... and it Worked
Something else that you can do is to change the "virtual access path". After checking Chrome's console and network view I noticed that the applications wasn't reaching the js
and css
resources since this was set to the name of the web project, so set this to /
and this did the trick.
Add below code in aspx file where crystal report exist.
<script src="../../aspnet_client/system_web/4_0_30319/crystalreportviewers13/js/crviewer/crv.js" type="text/javascript" >
</script>
Also copy aspnet_client folder from c:\inetpub\wwwroot folder to the new website root folder.
This method solve below two issues, Now working fine
I was also facing the same issue, got it resolved. when website is hosted through IIS, then Web.config needs to have below setting :
<add key="ResourceUri" value="~/crystalreportviewers13"/>
When website through is hosted through Visual Studio then
<add key="ResourceUri" value="/crystalreportviewers13"/>
i know this is a bit little old post but i think the novis like me can get help from this. add this code to your web.config file and copy "crystalreportviewers13" folder from "c:\inetpub\wwwroot\aspnet_client" to your root directory
<configSections>
<sectionGroup name="businessObjects">
<sectionGroup name="crystalReports">
<section name="rptBuildProvider" type="CrystalDecisions.Shared.RptBuildProviderHandler, CrystalDecisions.Shared, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304, Custom=null" />
<section name="crystalReportViewer" type="System.Configuration.NameValueSectionHandler" />
</sectionGroup>
</sectionGroup>
</configSections>
<businessObjects>
<crystalReports>
<rptBuildProvider>
<add embedRptInResource="true" />
</rptBuildProvider>
<crystalReportViewer>
<add key="ResourceUri" value="/crystalreportviewers13" />
</crystalReportViewer>
</crystalReports>
</businessObjects>
The solution is to work on IIS this way:
aspnet_client
folder from c:\inetpub\wwwroot
folder to the new website root folder.or (first one is easier, second one is better for maintenance)
aspnet_client
that points to c:\inetpub\wwwroot\aspnet_client
inside the new websiteIt's possible to analyze the problem
GET http://someserver:20080/aspnet_client/system_web/4_0_30319/crystalreportviewers13/js/crviewer/crv.js 403 (Forbidden)
GET
http://someserver:20080/aspnet_client/system_web/4_0_30319/crystalreportviewers13/js/crviewer/images/style.css 403 (Forbidden)
%SYSTEMROOT%\System32\LogFiles\W3SVC###\
on WIN2008 C:\inetpub\logs\LogFiles\W3SVC###
).2011-03-28 13:00:49 W3SVC701536 95.228.38.41 GET /aspnet_client/system_web/4_0_30319/crystalreportviewers13/js/crviewer/images/style.css - 20080 - 192.168.1.2 Mozilla/5.0+(compatible;+MSIE+9.0;+Windows+NT+6.1;+Trident/5.0) 403 6 64 Errore! 2011-03-28 13:00:49 W3SVC701536 95.228.38.41 GET /aspnet_client/system_web/4_0_30319/crystalreportviewers13/js/crviewer/crv.js - 20080 - 192.168.1.2 Mozilla/5.0+(compatible;+MSIE+9.0;+Windows+NT+6.1;+Trident/5.0) 403 6 64 Errore!
Crystal Reports runtime is installed, but your application is not running under default web site.
crv.js
and style.css
some files were not served; wwwroot\aspnet_client
folder, but for some reasons they cannot be reached; I can see that you use different versions of software and different configurations, but i think you have the same problem.