/// <summary> /// Initializes a new instance of the <see cref="ShowErrorForm" /> class. /// </summary> /// <param name="spdException">The SPD exception.</param> public ShowErrorForm(SPDException spdException) { InitializeComponent(); this.spdException = spdException; this.textBoxShortInfo.Text = spdException.GetShortInfo(); this.textBoxDetails.Text = spdException.GetDetailInfo(); }
/// Handles the SPD errors. /// </summary> /// <param name="e">The e.</param> private static void handleSPDError(Exception e) { SPDException spdExcetion; if (e is SPDException) { spdExcetion = (SPDException)e; } else { spdExcetion = new SPDException(e, null, null); } log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType).Fatal(spdExcetion.GetDetailInfo()); ShowErrorForm showErrorForm = new ShowErrorForm(spdExcetion); showErrorForm.ShowDialog(); Application.Exit(); }