Sub Application_Error(ByVal sender AsObject, ByVal e As EventArgs)
' Only log errors which did not originate from our components
IfNotTypeOf Server.GetLastError().InnerException() Is BizTierException AndNotTypeOf Server.GetLastError().InnerException() Is DbTierException Then
Log.WriteLogEntry(Server.GetLastError.GetBaseException, "Global.asax", "Application_Error")
EndIf
EndSub