コード例 #1
0
ファイル: Logger.cs プロジェクト: HasanFidan/PhotoUploader
        static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
        {
            int exceptionid = NextExceptionID;

            Basic.ErrorFormat("Unhandled exception occured. Error Number: {0}", exceptionid);
            Detail.Error(string.Format("Error Number: {0}", exceptionid), e.ExceptionObject as Exception);
        }
コード例 #2
0
ファイル: Logger.cs プロジェクト: HasanFidan/PhotoUploader
        public static void UnExpectedError(Exception exc, string message = "")
        {
            if (message == string.Empty)
            {
                message = "Unexpected exception occured.";
            }

            int exceptionid = NextExceptionID;

            Basic.ErrorFormat("{0} Error Number: {1}", message, exceptionid);
            Detail.Error(string.Format("Error Number: {0}", exceptionid), exc);
        }