启用会话状态在SharePoint 2010中? [英] Enabling Session State in SharePoint 2010?

查看:231
本文介绍了启用会话状态在SharePoint 2010中?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有专为SharePoint 2007的,我想移植到SharePoint 2010的Web服务这样的网络服务依赖于会话状态正常,但到目前为止,我已经能够获得会话状态在所有的工作SharePoint 2010中此Web服务作为下牛逼了自己的Web应用程序 他 / _ vti_bin 虚拟目录。我已经尝试了所有以下,没有运气的:

  • 保障了国家服务的服务应用程序运行。
  • 新增了 System.Web.SessionState.SessionStateModule HTTP模块,我的应用程序的web.config文件中。
  • 新增了 System.Web.SessionState.SessionStateModule HTTP模块,以我的SharePoint根Web.config文件。
  • 新增<网页ENABLESESSIONSTATE =真/> 来我的应用程序的web.config文件
  • 新增<网页ENABLESESSIONSTATE =真/> 来我的根web.config文件

其他环境信息:

  • 在Visual Studio 2008中 - SP1
  • 在.NET 3.5 - SP1
  • 在SharePoint 2010中 - RC
  • 在Windows Server 2008 R2
  • 在ASMX Web服务(不WCF)

没有任何人有任何运气得到一个Web应用程序的的Web服务使用会话状态在SharePoint 2010了吗?

谢谢!

史蒂夫

解决方案

您已经回答了这个自己其他地方的interweb。 :)

<的HttpModules>   <添加名称=会话类型=System.Web.SessionState.SessionStateModule/> < / HttpModules的>

然后,你必须进入你的web应用程序,并添加了相同的会话状态模块IIS7的托管管道。

  1. 打开IIS 7的经理,并找到自己的Web应用程序。

  2. 在IIS部分,双击模块。

  3. 点击添加托管模块...在右侧窗格中。

  4. 在添加托管模块对话框中,输入SessionState会或类似的东西的名称,并从下拉以下项目:

      

    System.Web.SessionState.SessionStateModule,System.Web程序,版本= 2.0.0.0,文化=中性公钥= b03f5f7f11d50a3a

在此之后,应启用会话状态,您的Web应用程序/ Web服务!

I have a web service built for SharePoint 2007 that I am trying to port to SharePoint 2010. This web service is dependent on session state to function properly, but so far, I have been enable to get session state to work at all in SharePoint 2010. This web service runs as its own web application under t he /_vti_bin virtual directory. I have tried all of the following with no luck:

  • Ensured the "State Service" service application is running.
  • Added the System.Web.SessionState.SessionStateModule http module to my application's web.config file.
  • Added the System.Web.SessionState.SessionStateModule http module to my SharePoint root web.config file.
  • Added <pages enableSessionState="true" /> to my application's web.config file.
  • Added <pages enableSessionState="true" /> to my root web.config file.

Additional Environment info:

  • Visual Studio 2008 - SP1
  • .NET 3.5 - SP1
  • SharePoint 2010 - RC
  • Windows Server 2008 R2
  • ASMX web service (not WCF)

Had anyone had any luck getting a web application or web service to use session state in SharePoint 2010 yet?

Thanks!

Steve

解决方案

You've already answered this yourself somewhere else on the interweb. :)

<httpModules> 
  <add name="Session" type="System.Web.SessionState.SessionStateModule" /> 
</httpModules>

THEN, you must go into your web application and add the same session state module to the IIS7 managed pipeline.

  1. Open IIS 7 manager, and find your web application.

  2. Double click "Modules" in the IIS section.

  3. Click "Add Managed Module..." on the right hand pane.

  4. In the Add Managed Module dialog, enter "SessionState" or something like that for the name, and choose the following item from the dropdown:

    System.Web.SessionState.SessionStateModule, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a

After that, session state should be enabled for your web app/web service!

这篇关于启用会话状态在SharePoint 2010中?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆