コード例 #1
0
        public void SelectOption()
        {
            Console.WriteLine(new string('*', 20));
            Console.WriteLine(new string('*', 20));
            Console.WriteLine("For...");
            Console.WriteLine("Show Data Select 1");
            Console.WriteLine("Insert Data Select 2");
            Console.WriteLine("Update Data Select 3");
            Console.WriteLine("Delete Data Select 4");
            Console.WriteLine();
            Console.Write("Your Selection :  ");
            int selection = Convert.ToInt32(Console.ReadLine());

            switch (selection)
            {
            case 1:
                ListWorkflow listwf = new ListWorkflow();
                listwf.Exe();
                break;

            case 2:
                AddWorkflow Addwf = new AddWorkflow();
                Addwf.Exe();
                break;

            case 3:
                UpdateWorkflow UpdateWF = new UpdateWorkflow();
                UpdateWF.Exe();
                break;

            default:
                break;
            }
        }
コード例 #2
0
        private static bool ProcessChoice()
        {
            string input = Console.ReadLine();

            switch (input)
            {
            case "1":
                ListWorkflow listwf = new ListWorkflow();
                listwf.Exe();
                break;

            case "2":
                AddWorkflow addwf = new AddWorkflow();
                addwf.Exe();
                break;

            case "3":
                UpdateWorkflow UWF = new UpdateWorkflow();
                UWF.Exe();
                break;

            case "4":
                DeleteWorkflow DWF = new DeleteWorkflow();
                DWF.Exe();
                break;

            default:
                Console.WriteLine("This is not a valid choice. Press any key to continue...");
                Console.ReadKey();
                break;
            }
            return(true);
        }
コード例 #3
0
        /// <summary>
        /// Переопределение для создания workflow.
        /// </summary>
        /// <returns>Рабочий процесс.</returns>
        protected override WorkflowArea CreateWorkflow()
        {
            var workflow = new ListWorkflow();

            return(workflow.Create());
        }