コード例 #1
0
ファイル: Program.cs プロジェクト: zzsssw/pdfbinder
        static void Main(string[] args)
        {
            // Start uninstallation if command line is /u {product-code}.
            if (args.Length == 2 && args[0].Equals("/u", StringComparison.OrdinalIgnoreCase))
            {
                Process msiexec = new Process();
                msiexec.StartInfo.FileName  = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.System), "msiexec.exe");
                msiexec.StartInfo.Arguments = "/i " + args[1];
                msiexec.Start();
            }
            else
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);

                Program.MainForm = new MainForm();

                ProcessLinker loader = new ProcessLinker();
                loader.SendFileList(args);

                if (loader.IsServer || args.Length == 0)
                {
                    Application.Run(Program.MainForm);
                }
            }
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: schourode/pdfbinder
        static void Main(string[] args)
        {
            // Start uninstallation if command line is /u {product-code}.
            if (args.Length == 2 && args[0].Equals("/u", StringComparison.OrdinalIgnoreCase))
            {
                Process msiexec = new Process();
                msiexec.StartInfo.FileName = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.System), "msiexec.exe");
                msiexec.StartInfo.Arguments = "/i " + args[1];
                msiexec.Start();
            }
            else
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);

                Program.MainForm = new MainForm();

                var fileNames = new string[args.Length];
                Array.Copy(args, fileNames, args.Length);
                Array.Sort(fileNames);

                var loader = new ProcessLinker();
                loader.SendFileList(fileNames);

                if (loader.IsServer || args.Length == 0)
                {
                    Application.Run(Program.MainForm);
                }
            }
        }
コード例 #3
0
        static void Main(string[] args)
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            MainForm = new MainForm();

            var fileNames = new string[args.Length];
            Array.Copy(args, fileNames, args.Length);
            Array.Sort(fileNames);

            var loader = new ProcessLinker();
            loader.SendFileList(fileNames);

            if (loader.IsServer || args.Length == 0)
            {
                Application.Run(MainForm);
            }
        }