using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Threading.Tasks;
using System.Windows;
namespace FLY.Weight2.UI.Server
{
/// <summary>
/// App.xaml 的交互逻辑
/// </summary>
public partial class App : Application
{
FLY.AppHelper.AppJustOne appjustone;
NLog.Logger log = NLog.LogManager.GetCurrentClassLogger();
public App()
{
appjustone = new AppHelper.AppJustOne(this);
AppDomain.CurrentDomain.UnhandledException += (s, e) =>
{
log.Error((Exception)e.ExceptionObject, "AppDomain.CurrentDomain.UnhandledException");
string err = e.ExceptionObject.ToString();
MessageBox.Show("程序出现异常,请把下面信息拍照发给厂家" + Environment.NewLine + err,
"异常,联系厂家",
MessageBoxButton.OK, MessageBoxImage.Error);
};
}
}
}
-
潘栩锋 authoredf04f3275