Ejemplo n.º 1
0
        public static int LogWarning(string methodName, string errorMessage)
        {
            var    ipaddress       = AuditService.DetermineIPAddress();
            var    ComputerDetails = AuditService.DetermineCompName(ipaddress);
            string MethodName      = Constants.AuditActionType.CustomerAccount.ToString();
            int    insertError     = 0;
            ILog   myLog           = LogManager.GetLogger(methodName);

            myLog.WarnFormat(errorMessage);

            return(insertError);
        }
Ejemplo n.º 2
0
        public static int LogError(string methodName, Exception ex)
        {
            var    ipaddress       = AuditService.DetermineIPAddress();
            var    ComputerDetails = AuditService.DetermineCompName(ipaddress);
            string MethodName      = Constants.AuditActionType.CustomerAccount.ToString();
            int    insertError     = 0;
            ILog   myLog           = LogManager.GetLogger(methodName);

            myLog.Debug("Message: " + ex.Message + "|StackTrace: " + ex.StackTrace);

            return(insertError);
        }