Rob*_*Rob 10 sharepoint moss elmah
有没有人将ELMAH集成到他们的SharePoint环境中?
我想这是可能的,因为它是所有的ASP.net,但我只是想知道是否有人做过它,如果有一个如何实现它的步骤?
在设置ELMAH或者Sharepoint中的大多数HTTPModule时,重要的一点是它们需要位于httpModules部分的开头.否则,SharePoint将基本上吞下该异常,并且不会调用ELMAH功能
作品
<clear />
<add name="ErrorMail" type="Elmah.ErrorMailModule, Elmah"/>
<add name="ErrorLog" type="Elmah.ErrorLogModule, Elmah"/>
<add name="ErrorFilter" type="Elmah.ErrorFilterModule, Elmah"/>
<add name="SPRequest" type="Microsoft.SharePoint.ApplicationRuntime.SPRequestModule, Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" />
<add name="OutputCache" type="System.Web.Caching.OutputCacheModule" />
<add name="FormsAuthentication" type="System.Web.Security.FormsAuthenticationModule" />
... Rest of SharePoint modules....
Run Code Online (Sandbox Code Playgroud)
不行
<clear />
<add name="SPRequest" type="Microsoft.SharePoint.ApplicationRuntime.SPRequestModule, Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" />
<add name="OutputCache" type="System.Web.Caching.OutputCacheModule" />
<add name="FormsAuthentication" type="System.Web.Security.FormsAuthenticationModule" />
... Rest of SharePoint modules....
<add name="ErrorMail" type="Elmah.ErrorMailModule, Elmah"/>
<add name="ErrorLog" type="Elmah.ErrorLogModule, Elmah"/>
<add name="ErrorFilter" type="Elmah.ErrorFilterModule, Elmah"/>
Run Code Online (Sandbox Code Playgroud)
我们在MOSS 2007环境中使用ELMAH.由于ELMAH使用HttpHandlers并通过web.config设置,因此激活它很简单.只需将ELMAH内容添加到您在SharePoint中运行的应用程序的web.config中.
如果希望ELMAH报告的错误级别高于自定义应用程序,请将其添加到SharePoint web.config中.
| 归档时间: |
|
| 查看次数: |
1850 次 |
| 最近记录: |