/[AnywhereTS-MSSQL]/trunk/TSAdminTool/Program.cs
ViewVC logotype

Diff of /trunk/TSAdminTool/Program.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

--- trunk/TSAdminTool/Program.cs	2012/07/12 19:07:58	65
+++ trunk/TSAdminTool/Program.cs	2012/07/12 19:23:51	66
@@ -3,6 +3,8 @@
 using System.Windows.Forms;
 using log4net;
 using System.Data.SqlClient;
+using System.Collections;
+using System.Text;
 
 namespace AnywhereTS
 {
@@ -42,6 +44,13 @@
                 {
                     Logging.ATSAdminLog.Error("Encountered unhandled SqlException");
                 }
+                Stack stack = log4net.NDC.CloneStack();
+                List<object> strs = new List<object>(stack.ToArray());
+                strs.Reverse();
+                StringBuilder builder = new StringBuilder();
+                foreach (object str in strs) { builder.AppendLine(str.ToString()); }
+                builder.AppendLine("Encountered unhandled Exception");
+                MessageBox.Show(builder.ToString());
             }
             else
             {
@@ -49,6 +58,13 @@
                 {
                     Logging.ATSAdminLog.Error("Encountered unhandled Exception");
                 }
+                Stack stack = log4net.NDC.CloneStack();
+                List<object> strs = new List<object>(stack.ToArray());
+                strs.Reverse();
+                StringBuilder builder = new StringBuilder();
+                foreach (object str in strs) { builder.AppendLine(str.ToString()); }
+                builder.AppendLine("Encountered unhandled Exception");
+                MessageBox.Show(builder.ToString());
             }
         }
     }

 

  ViewVC Help
Powered by ViewVC 1.1.22