示例#1
0
        public void ReportException(ExceptionInfo exceptionInfo)
        {
            if (!IsEnabled())
            {
                return;
            }

            if (exceptionInfo == null)
            {
                return;
            }

            ExceptionServerInfo serverInfo = new ExceptionServerInfo();

            serverInfo.FileName   = exceptionInfo.FileName;
            serverInfo.LineNumber = exceptionInfo.LineNumber;
            serverInfo.Message    = exceptionInfo.Message;
            serverInfo.Data       = exceptionInfo.Data;
            serverInfo.IPAddress  = HttpContext.Current.Request.UserHostAddress;
            serverInfo.UserAgent  = HttpContext.Current.Request.UserAgent;

            //Raise Event
            if (OnClientException != null)
            {
                OnClientException(new object(), new ClientExceptionEventArgs(serverInfo));
            }
        }
        public void ReportException(ExceptionInfo exceptionInfo) {
            if (!IsEnabled())
                return;

            if (exceptionInfo == null)
                return;

            ExceptionServerInfo serverInfo = new ExceptionServerInfo();
            serverInfo.FileName = exceptionInfo.FileName;
            serverInfo.LineNumber = exceptionInfo.LineNumber;
            serverInfo.Message = exceptionInfo.Message;
            serverInfo.Data = exceptionInfo.Data;
            serverInfo.IPAddress = HttpContext.Current.Request.UserHostAddress;
            serverInfo.UserAgent = HttpContext.Current.Request.UserAgent;

            //Raise Event
            if (OnClientException != null)
                OnClientException(new object(), new ClientExceptionEventArgs(serverInfo));

        }
示例#3
0
 public ClientExceptionEventArgs(ExceptionServerInfo exceptionServerInfo)
 {
     _exceptionServerInfo = exceptionServerInfo;
 }
 public ClientExceptionEventArgs(ExceptionServerInfo exceptionServerInfo) {
     _exceptionServerInfo = exceptionServerInfo;
 }