Пример #1
0
        public void ListMaker(string comment2) // command used for creating lists
        {
            Console.WriteLine("This command is now replaced by the Project Manager command(which is located in the start menu)");
            Console.WriteLine("If you still want to run the ListMaker then we do have an earlier version of it\nType '/command Version'");
            string cRead = Console.ReadLine();

            if (cRead == "/command Version") // If you want to run the old version of this app
            {
                ProcessHandler handler = new ProcessHandler();
                handler.ProcessHandle();
                Thread.Sleep(1000);
                Console.WriteLine("Type Exit");
                Console.Write(">");
                string Read = Console.ReadLine();
                if (Read == "Exit")
                {
                    Console.WriteLine("Exiting");
                    Thread.Sleep(100);
                    viOne v = new viOne();
                    v.vi();
                }
            }
            else if (cRead == "/command Reject" || cRead == "/Exit" || cRead == "exit" || cRead == "Exit" || cRead == "-state=down") // If you want to exit
            {
                Console.WriteLine("Exiting ");
                Thread.Sleep(100);
                viOne v = new viOne();
                v.vi();
            }
            else
            {
                Console.WriteLine("Wrong command");
                ListMaker("Make list");
            }
        }
Пример #2
0
        public void WriteConsolePad()
        {
            Console.Clear();
            Console.WriteLine("Do you want to start the old version or Normal version('Normal' for normal and '/version old' for old version)");
            Console.Write(">");
            string commandOpen = Console.ReadLine();

            if (commandOpen == "/command Exit")
            {
                viOne v = new viOne();
                v.vi();
            }
            else if (commandOpen == "/version old") // If you want to run the old version
            {
                Console.WriteLine("Opening");
                Thread.Sleep(1000);
                ProcessHandler handler = new ProcessHandler();
                handler.ProcessWritePadUI();
                Console.WriteLine("Exiting");
                Thread.Sleep(1000);
                viOne n = new viOne();
                n.vi();
            }
            else if (commandOpen == "Normal") // If you want to run the normal version
            {
                Console.WriteLine("What writing software do you want to open?");
                Console.WriteLine(">");
                string           readApp   = Console.ReadLine();
                ProcessStartInfo startInfo = new ProcessStartInfo();
                startInfo.Arguments       = $@"/C {readApp}";
                startInfo.UseShellExecute = true;
                Process.Start(startInfo);
                Thread.Sleep(2000);
                Console.WriteLine("Type Exit or Stay");
                Console.Write(">");
                string rcommand = Console.ReadLine();
                if (rcommand == "Exit")
                {
                    viOne v = new viOne();
                    v.vi();
                }
                else if (rcommand == "Stay")
                {
                    WriteConsolePad();
                }
                else
                {
                    Console.WriteLine("Wrong command");
                    Thread.Sleep(100);
                    WriteConsolePad();
                }
            }

            else if (commandOpen == "/version dev")
            {
                Console.WriteLine("In developemnt");
                Console.WriteLine("Writing to the input stream");
                Thread.Sleep(100);
                Console.WriteLine("Opening a edit::access input stream in Falcon::input-edit");
                Thread.Sleep(1000);
                Console.WriteLine("Write ':goto' to start Falcon::Input-edit or type '/Exit' to exit");
                string commandWrite = Console.ReadLine();
                if (commandWrite == ":goto")
                {
                }
                else if (commandWrite == "/Exit")
                {
                    var back = new viOne();
                    back.vi();
                }
            }

            else
            {
                Console.WriteLine(
                    "Wrong command"
                    );
                Thread.Sleep(100);
                WriteConsolePad();
            }
        }