示例#1
0
            public static void LogError(Exception ex)
            {
                StringBuilder sb = new StringBuilder();

                //sb.Append("< !DOCTYPE html >");
                //sb.Append("< html >");
                //sb.Append("< head >");
                //sb.Append("</ head >");
                //sb.Append("< body>");
                sb.Append("<strong><h5>PAGINA: </h5></strong>" + HttpContext.Current.Request.Url.AbsoluteUri + " <br/>");
                sb.Append(" <br/>");
                sb.Append("<strong><h5>ERROR: </h5></strong>" + ex.Message.ToString() + " <br/>");
                sb.Append(" <br/>");
                sb.Append("<strong><h5>EXCEPCION: </h5></strong>" + ex.InnerException.ToString() + " <br/>");
                //sb.Append("</ body >");
                //sb.Append("</ html >");
                //"PAGINA: " + HttpContext.Current.Request.Url.AbsoluteUri + "; ERROR: " + ex.Message.ToString() + "; EXCEPCION: " + ex.InnerException.ToString()
                Comunes.EnviarCorreo("[email protected],[email protected]", "ERROR SIGES", sb.ToString());
            }