58 lines
1.5 KiB
C#
58 lines
1.5 KiB
C#
using Serilog;
|
|
using System;
|
|
using System.IO;
|
|
using System.Windows;
|
|
using System.Windows.Controls;
|
|
using System.Windows.Input;
|
|
|
|
namespace wpf_ax_utility
|
|
{
|
|
public partial class MainWindow : Window
|
|
{
|
|
public MainWindow()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void MouseLeftDrag(object sender, MouseButtonEventArgs e)
|
|
{
|
|
DragMove();
|
|
}
|
|
|
|
private void CloseButton(object sender, RoutedEventArgs e)
|
|
{
|
|
Close();
|
|
}
|
|
|
|
private void ButtonClicked(object sender, RoutedEventArgs e)
|
|
{
|
|
Utility.AucCleaner();
|
|
|
|
string AxArgs = string.Empty;
|
|
|
|
switch (((Button)sender).Name)
|
|
{
|
|
case "LIVE":
|
|
AxArgs = @"-regConfig=axc\PAL_LIVE_USR.axc";
|
|
break;
|
|
case "LIVE02":
|
|
AxArgs = @"-regConfig=axc\PAL_LIVE_02_USR.axc";
|
|
break;
|
|
case "DEV":
|
|
AxArgs = @"-regConfig=axc\PAL_DEVELOP_USR.axc";
|
|
break;
|
|
case "TEST":
|
|
AxArgs = @"-regConfig=axc\PAL_TEST_USR.axc";
|
|
break;
|
|
case "STAGING":
|
|
AxArgs = @"-regConfig=axc\PAL_STAGING_USR.axc";
|
|
break; ;
|
|
}
|
|
|
|
Utility.AxExecution(AxArgs);
|
|
|
|
Log.Logger.Information("Running AX client with this parameter: " + AxArgs);
|
|
}
|
|
}
|
|
}
|