0

我們主持了新網站,我使用asp.net創建了3個報表 MS報表(報表查看器)。在服務器上使用報表查看器顯示報表VS 2010

我在本地發佈了它,它工作的很好,但是我現在拷貝到服務器的東西不會顯示報告,而是要求身份驗證。提供用戶名和密碼後,它只是顯示一個空白頁面。

而且還可以手動我 傳輸的所有.rdlc文件到報告文件夾我複製的數據集 到應用程序文件夾。

這裏是我的web.config

<?xml version="1.0"?> 
<!-- For more information on how to configure your ASP.NET application, please visit http://go.microsoft.com/fwlink/?LinkId=169433 --> 
<configuration> 
    <appSettings> 
     <add key="CrystalImageCleaner-AutoStart" value="true" /> 
     <add key="CrystalImageCleaner-Sleep" value="60000" /> 
     <add key="CrystalImageCleaner-Age" value="120000" /> 
    </appSettings> 
    <system.web> 
     <sessionState timeout="20"/> 
     <compilation targetFramework="4.0"> 
      <assemblies> 
       <add assembly="CrystalDecisions.CrystalReports.Engine, Version=13.0.2000.0, ulture=neutral, PublicKeyToken=692fbea5521e1304"/> 
       <add assembly="CrystalDecisions.ReportSource, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" /> 
       <add assembly="CrystalDecisions.Shared, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" /> 
       <add assembly="CrystalDecisions.Web, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" /> 
       <add assembly="CrystalDecisions.ReportAppServer.ClientDoc, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" /> 
       <add assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" /> 
       <add assembly="Microsoft.ReportViewer.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" /> 
       <add assembly="Microsoft.Build.Framework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" /> 
       <add assembly="System.Management, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" /> 
      </assemblies> 
      <buildProviders> 
       <add extension=".rdlc" type="Microsoft.Reporting.RdlBuildProvider, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> 
      </buildProviders> 
     </compilation> 
     <globalization requestEncoding="iso-8859-1" responseEncoding="iso-8859-1" /> 
     <httpHandlers> 
      <add path="CrystalImageHandler.aspx" verb="GET" type="CrystalDecisions.Web.CrystalImageHandler, CrystalDecisions.Web, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" /> 
      <add path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" validate="false" /> 
     </httpHandlers> 
    </system.web> 
    <connectionStrings> 
     <add name="constr" connectionString="Data Source=SQLEXPRESS; Initial Catalog =databasename; User Id = user; Password = pwd;" /> 
     <add name="iCAMSConnectionString" connectionString="Data Source=SQLEXPRESS;Initial Catalog=databasename;Persist Security Info=True;User ID=user;Password=pwd" providerName="System.Data.SqlClient" /> 
    </connectionStrings> 
    <system.webServer> 
     <handlers> 
      <add name="CrystalImageHandler.aspx_GET" verb="GET" path="CrystalImageHandler.aspx" type="CrystalDecisions.Web.CrystalImageHandler, CrystalDecisions.Web, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" preCondition="integratedMode" /> 
      <add name="ReportViewerWebControlHandler" preCondition="integratedMode" verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> 
     </handlers> 
     <validation validateIntegratedModeConfiguration="false" /> 
    </system.webServer> 
</configuration> 

而且我一直都.DLLbin,例如:

Microsoft.ReportViewer.WebForms 
Microsoft.ReportViewer.Common 

和報告(.rdlc)報告文件夾中

請任何人都可以幫助我,我嘗試了很多,但我不知道我在哪裏丟失 。

謝謝。

回答

1

更改到您的示例如下:

<handlers> 
    <add name="CrystalImageHandler.aspx_GET" 
     verb="GET" path="CrystalImageHandler.aspx" 
     type="CrystalDecisions.Web.CrystalImageHandler, CrystalDecisions.Web, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304" 
     preCondition="integratedMode"/> 
</handlers> 
+0

<添加名稱= 「CrystalImageHandler.aspx_GET」 動詞= 「GET」 路徑= 「CrystalImageHandler.aspx」 TYPE =「CrystalDecisions.Web.CrystalImageHandler,CrystalDecisions .Web,Version = 13.0.2000.0,Culture = neutral,PublicKeyToken = 692fbea5521e1304「preCondition =」integratedMode「/> pati 2012-06-05 10:55:04

+1

請不要將該代碼作爲評論發佈。編輯你的答案並在那裏添加代碼,然後刪除你的評論。 – 2012-06-05 10:59:36

+0

感謝Pati的回覆,但是我通過部署項目(之前已經發布了項目數據)解決了這個問題,並且在解決了我的問題後,在服務器中安裝了報表查看器支持文件。 – 2012-06-05 12:23:56

相關問題