Esempio n. 1
0
 private void button1_Click(object sender, EventArgs e)
 {
     if (txtOutputFile.Text == "" || txtPath.Text == "")
     {
         MessageBox.Show("A path and output file must be entered");
     }
     else
     {
         System.Windows.Forms.Cursor.Current = System.Windows.Forms.Cursors.WaitCursor;
         CombineScripts s = new CombineScripts(txtPath.Text, txtOutputFile.Text, false);
         System.Windows.Forms.MessageBox.Show("Script completed");
         System.Windows.Forms.Cursor.Current = System.Windows.Forms.Cursors.Default;
     }
 }
Esempio n. 2
0
        static void Main()
        {
            string[] line = Environment.GetCommandLineArgs();

            // if we are supplied a path then don't display a UI
            // just combine the scripts in that folder and exit
            if (line.Length > 2)
            {
                string folderPath = line[1];
                string saveFileAs = line[2];

                CombineScripts c = new CombineScripts(folderPath, saveFileAs, true);
                Console.WriteLine("Script generated.");
            }
            else
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
                Application.Run(new frmScript());
            }
        }