错误:Option Strict On不允许缩小方法'context_beginRequest<ByVal sender As Object, ByVal e As WindowsAuthenticationEventArgs>'
和委托'<BeginRequest>'
代码:
Public Sub Init(ByVal context As System.Web.HttpApplication) Implements System.Web.IHttpModule.Init
'context.
AddHandler context.BeginRequest, New EventHandler(AddressOf context_BeginRequest)
End Sub
context_BeginRequest函数::
Public Sub context_BeginRequest(ByVal sender As Object, ByVal e As WindowsAuthenticationEventArgs)
.....
..... 结束子
答案 0 :(得分:0)
这是因为HttpApplication.BeginRequest
只是EventHandler
类型...所以你的第二个参数应该是EventArgs
类型,而不是WindowsAuthenticationEventArgs
。