我試圖配置ELMAH錯誤日誌中使用SQL Server 2008 R2的ASP.NET 4應用SQL Server日誌記錄。有什麼方法可以告訴ELMAH在我們提供的連接字符串上調用我們的內部解密函數?我需要修改ELMAH源並重建嗎?配置ELMAH與加密的連接字符串
<configSections>
<sectionGroup name="elmah">
<section name="security" requirePermission="false" type="Elmah.SecuritySectionHandler, Elmah" />
<section name="errorLog" requirePermission="false" type="Elmah.ErrorLogSectionHandler, Elmah" />
<section name="errorMail" requirePermission="false" type="Elmah.ErrorMailSectionHandler, Elmah" />
<section name="errorFilter" requirePermission="false" type="Elmah.ErrorFilterSectionHandler, Elmah" />
</sectionGroup>
</configSections>
<elmah>
<security allowRemoteAccess="1" />
<errorLog type="Elmah.SqlErrorLog, Elmah" connectionStringName="ELMAH" />
</elmah>
<connectionStrings>
<add name="ELMAH" connectionString="EncryptedConnectionString" providerName="System.Data.SqlClient" />
</connectionStrings>
<system.webServer>
<handlers>
<add name="Elmah" verb="POST,GET,HEAD" path="elmah.axd" type="Elmah.ErrorLogPageFactory, Elmah" preCondition="integratedMode" />
</handlers>
<modules>
<add name="ErrorLog" type="Elmah.ErrorLogModule, Elmah" />
</modules>
</system.webServer>
什麼是這個代碼示例中的「父(上下文)」嗎? – Doug 2013-04-17 00:28:16