>Dim o As Object = Context.Handler >Dim h As Object = o.GetType() >Thank you, this works:
Sub Application_PreRequestHandlerExecute(ByVal sender As Object, ByVal e As EventArgs) Dim loContext As Object = Context.Handler Dim loType As Object = loContext.GetType() Dim lcType As String = loType.ToString ' .vb and .config not accepted If lcType = "System.Web.HttpForbiddenHandler" Then Response.Redirect("Default.aspx") End If Dim loPage As System.Web.UI.Page = Context.Handler LXFramework.oPage = loPage End Sub