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

Diff of /trunk/TSAdminTool/ProSupport.cs

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

--- trunk/TSAdminTool/ProSupport.cs	2012/07/11 18:48:42	20
+++ trunk/TSAdminTool/ProSupport.cs	2012/07/12 14:17:14	46
@@ -248,6 +248,13 @@
                 catch (Exception e)
                 {
                     MessageBox.Show("Could not update TFTP server '" + GetTftpPath(row) + "' (22181). Error: " + e.Message);
+                    using (log4net.NDC.Push(string.Format("SqlException: MESSAGE={0}{1}Diagnostics:{1}{2}", e.Message, System.Environment.NewLine, e.ToString())))
+                    {
+                        using (log4net.NDC.Push(string.Format("tftpPath={0}", GetTftpPath(row))))
+                        {
+                            Logging.ATSAdminLog.Error("Could not update TFTP server");
+                        }
+                    }
                 }
             
                 // Try to set rights for image the image file
@@ -283,6 +290,13 @@
                 catch (Exception e)
                 {
                     MessageBox.Show("Could not update TFTP server '" + GetTftpPath(row) + "' (22381). Error: " + e.Message);
+                    using (log4net.NDC.Push(string.Format("SqlException: MESSAGE={0}{1}Diagnostics:{1}{2}", e.Message, System.Environment.NewLine, e.ToString())))
+                    {
+                        using (log4net.NDC.Push(string.Format("tftpPath={0}", GetTftpPath(row))))
+                        {
+                            Logging.ATSAdminLog.Error("Could not update TFTP server");
+                        }
+                    }
                 }
             }
         }
@@ -302,6 +316,10 @@
                 catch (Exception ex)
                 {
                     MessageBox.Show("Cannot set access rights for client configuration. Application will abort. Error: " + ex.Message);
+                    using (log4net.NDC.Push(string.Format("SqlException: MESSAGE={0}{1}Diagnostics:{1}{2}", ex.Message, System.Environment.NewLine, ex.ToString())))
+                    {
+                        Logging.ATSAdminLog.Error("Cannot set access rights for client configuration");
+                    }
                     Application.Exit();
                     return;
                 }
@@ -364,6 +382,13 @@
             {
                 //improve autoretry
                 MessageBox.Show("Error: Could not write configuration data to disk. Possibly the data is being accessed by another component right now or you do not have the sufficient rights. Please retry this operation later (52044). Error details: " + e.Message);
+                using (log4net.NDC.Push(string.Format("SqlException: MESSAGE={0}{1}Diagnostics:{1}{2}", e.Message, System.Environment.NewLine, e.ToString())))
+                {
+                    using (log4net.NDC.Push(string.Format("path={0}", path)))
+                    {
+                        Logging.ATSAdminLog.Error("Could not write configuration data to disk");
+                    }
+                }
             }
 
             finally

 

  ViewVC Help
Powered by ViewVC 1.1.22