Initial commit almost identical to SVN-repo rev.340

This commit is contained in:
Milan Hanajik
2014-07-28 09:56:40 +02:00
commit 175a92f633
575 changed files with 186534 additions and 0 deletions
+31
View File
@@ -0,0 +1,31 @@
using System;
using System.Windows.Forms;
using TBF.Forms;
using TBF.Resources;
namespace TBF.ErrorHandler {
public static class ErrorHandler
{
public static DialogResult HandleError(Exception e, string Message, string Origin)
{
//catch (FluentNHibernate.Cfg.FluentConfigurationException fe)
// {
// string message;
// if (fe.InnerException != null)
// {
// message = fe.InnerException.Message;
// }
// else
// {
// message = fe.Message;
// }
// MessageBox.Show( message, "RetVal", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
ErrorDlg dlg = new ErrorDlg(Strings.Unhandled_error_occured_in_ + Origin + Environment.NewLine + Message + Environment.NewLine + e.ToString() + Environment.NewLine + e.InnerException.ToString());
dlg.ShowDialog();
return dlg.returnvalue;
}
}
}