Пример #1
0
        static void Main(string[] arguments)
        {
            Action <string[]> method = (args) =>
            {
                // Check if this is a "MakeDefault" call
                if (args != null && args.Length > 0 && args[0] == "MakeDefault")
                {
                    if (DefaultAssociationHelper.MakeDefaultInternal(null))
                    {
                        Environment.ExitCode = 101;
                    }
                    return;
                }

                string file = null;
                if (args != null)
                {
                    file = args.Where(s => File.Exists(s)).FirstOrDefault();
                }

                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
                Application.Run(new MainForm(file));
            };

            AppProgram.Start(
                applicationName: "SvclogViewer",
                authorName: "Martijn Stolk",
                reportBugEndpoint: "http://martijn.tikkie.net/reportbug.php",
                args: arguments,
                mainMethod: method);
        }
Пример #2
0
        public List <AppProgram> getProgramList()
        {
            DBUtils           dbUtils1             = new DBUtils();
            SqlDataReader     attributeListReader1 = dbUtils1.readOperation("SELECT * FROM App_Program");
            List <AppProgram> programList          = new List <AppProgram>();

            while (attributeListReader1.Read())
            {
                AppProgram att2 = new AppProgram();

                att2.programId   = (int)attributeListReader1["program_id"];
                att2.programName = attributeListReader1["program_name"].ToString();
                programList.Add(att2);
            }
            dbUtils1.closeDBConnection();
            return(programList);
        }
Пример #3
0
        static void Main(string[] arguments)
        {
            Action <string[]> mainMethod = (args) =>
            {
                XmlConfigurator.Configure();
                Logger.Info("Starting...");
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
                Application.Run(new MainForm());
            };

            AppProgram.Start(
                "AzureCloudserviceDeployer",
                "Martijn Stolk",
                "http://martijn.tikkie.net/reportbug.php",
                "http://martijn.tikkie.net/feedback.php",
                mainMethod,
                arguments);
        }
Пример #4
0
        static void Main(string[] arguments)
        {
            Action <string[]> method = (args) =>
            {
                XmlConfigurator.Configure();
                Logger.Info("Starting...");
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
                var form = new MainForm();
                Application.Run(form);
            };

            AppProgram.Start(
                applicationName: "AzureLogViewer",
                authorName: "Martijn Stolk",
                reportBugEndpoint: "http://martijn.tikkie.net/reportbug.php",
                feedbackEndpoint: "http://martijn.tikkie.net/feedback.php",
                args: arguments,
                mainMethod: method);
        }