SharePoint2013使用ReportViewer控件(原)

-------------------编写人:Lidan-------------------

前面有写过SharePoint2010中使用ReportViewer的,现把SharePoint2013中使用的配置也写一下,能供大家参考

(1)    <handlers></handlers>结点中添加如下内容(须添加在结点下第一行)

<add name="ReportViewerWebControlHandler" preCondition="integratedMode" verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />

 

(2)    <httpHandlers></httpHandlers>结点中添加如下内容(须添加在结点下第一行)

<add verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />

 

(3)    <modules runAllManagedModulesForAllRequests=”true”>结点下,注释

<remove name=”Session” />

 

(5)    <pages enableSessionState=”false” enableViewState=”true” …/>修改为

<pages enableSessionState=”true” enableViewState=”true” …/>

 

(6)    <appSettings></appSettings>结点中注释

<add key="ReportViewerMessages" value="Microsoft.SharePoint.Portal.Analytics.UI.ReportViewerMessages, Microsoft.SharePoint.Portal, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" />

 

-------------------------------另:如果遇到此错误-------------------------------

Unable to serialize the session state. In 'StateServer' and 'SQLServer' mode, ASP.NET will serialize the session state objects, and as a result non-serializable objects or MarshalByRef objects are not permitted. The same restriction applies if similar serialization is done by the custom sessionstate store in 'Custom' mode.

解决方案:

将<sessionState mode="SQLServer" timeout="60" allowCustomSqlDatabase="true" sqlConnectionString=.../>

修改为<sessionState mode="InProc" timeout="60" allowCustomSqlDatabase="true" sqlConnectionString=.../>

 

 

 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值