12345678910111213141516171819202122232425262728293031323334353637 |
- using System.Runtime.InteropServices;
- namespace PictureMover
- {
- internal static class Program
- {
- internal static string[] CommandLineArgs { get; private set; }
- [DllImport("kernel32.dll", SetLastError = true, ExactSpelling = true)]
- static extern bool FreeConsole();
-
-
-
- [STAThread]
- private static void Main(string[] args)
- {
- if (Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT") != "Development")
- {
- try
- {
- FreeConsole();
- }
- catch
- {
-
- }
- }
- CommandLineArgs = args;
-
-
- ApplicationConfiguration.Initialize();
- Application.Run(new MainForm());
- }
- }
- }
|