static void Main() { // Initialize the user interface. Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationType = ApplicationType.Client; application.ConfigSectionName = "TutorialClient"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // load the application configuration. application.LoadApplicationConfiguration(false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // run the application interactively. Application.Run(new MainForm(application.ApplicationConfiguration)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationName = "UA Server Test Tool"; application.ApplicationType = ApplicationType.Client; application.ConfigSectionName = "Opc.Ua.ServerTestTool"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // run the application interactively. Application.Run(new MainForm()); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { ReportGenerator g = new ReportGenerator(); g.Initialize(); g.GenerateFluidLevelTestReport(); g.GenerateFluidLevelTestReport(); g.GenerateFluidLevelTestReport(); // Initialize the user interface. Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationType = ApplicationType.Server; application.ConfigSectionName = "HistoricalEventsServer"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // check if running as a service. if (!Environment.UserInteractive) { application.StartAsService(new HistoricalEventsServer()); return; } // load the application configuration. application.LoadApplicationConfiguration(false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // start the server. application.Start(new HistoricalEventsServer()); // run the application interactively. Application.Run(new ServerForm(application)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationName = "UA Sample Server"; application.ApplicationType = ApplicationType.Server; application.ConfigSectionName = "Opc.Ua.SampleServer"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // check if running as a service. if (!Environment.UserInteractive) { application.StartAsService(new SampleServer()); return; } // load the application configuration. application.LoadApplicationConfiguration(false); // This call registers the certificate with HTTP.SYS // It must be called once after installation if the HTTPS endpoint is enabled. // HttpAccessRule.SetHttpsCertificate(c.SecurityConfiguration.ApplicationCertificate.Find(true), 51212, false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // start the server. application.Start(new SampleServer()); // run the application interactively. Application.Run(new ServerForm(application)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { // Initialize the user interface. Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationType = ApplicationType.Server; application.ConfigSectionName = "HistoricalAccessServer"; try { // DoTests(false, false, "Quickstarts.HistoricalAccessServer.Data.Historian1.txt", "..\\..\\Data\\Historian1ExpectedData.csv"); // DoTests(false, true, "Quickstarts.HistoricalAccessServer.Data.Historian2.txt", "..\\..\\Data\\Historian2ExpectedData.csv"); // DoTests(true, true, "Quickstarts.HistoricalAccessServer.Data.Historian3.txt", "..\\..\\Data\\Historian3ExpectedData.csv"); // process and command line arguments. if (application.ProcessCommandLine()) { return; } // check if running as a service. if (!Environment.UserInteractive) { application.StartAsService(new HistoricalAccessServer()); return; } // load the application configuration. application.LoadApplicationConfiguration(false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // start the server. application.Start(new HistoricalAccessServer()); // run the application interactively. Application.Run(new ServerForm(application)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationName = "UA COM Server Wrapper"; application.ApplicationType = ApplicationType.Server; application.ConfigSectionName = "Opc.Ua.ComServerWrapper"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // check if running as a service. if (!Environment.UserInteractive) { application.StartAsService(new ComWrapperServer()); return; } // load the application configuration. application.LoadApplicationConfiguration(false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // start the server. application.Start(new ComWrapperServer()); // run the application interactively. Application.Run(new ServerForm(application)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { ApplicationInstance application = new ApplicationInstance(); application.ApplicationType = ApplicationType.Server; application.ConfigSectionName = "PerfTestServer"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // check if running as a service. if (!Environment.UserInteractive) { application.StartAsService(new PerfTestServer()); return; } // load the application configuration. application.LoadApplicationConfiguration(false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // start the server. application.Start(new PerfTestServer()); // run the application interactively. Application.Run(new Opc.Ua.Server.Controls.ServerForm(application)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationName = "UA Publisher"; application.ApplicationType = ApplicationType.ClientAndServer; application.ConfigSectionName = "Opc.Ua.Publisher"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // load the application configuration. application.LoadApplicationConfiguration(false); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // start the server. application.Start(new SampleServer()); // allow UA servers to use the same certificate for HTTPS validation. ApplicationInstance.SetUaValidationForHttps(application.ApplicationConfiguration.CertificateValidator); // run the application interactively. Application.Run(new SamplePublisherForm(application, null, application.ApplicationConfiguration)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }
static void Main() { // Initialize the user interface. Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); ApplicationInstance application = new ApplicationInstance(); application.ApplicationType = ApplicationType.Client; application.ConfigSectionName = "DataTypesClient"; try { // process and command line arguments. if (application.ProcessCommandLine()) { return; } // load the application configuration. application.LoadApplicationConfiguration(false); // add the encodable types defined in the shared information model library. application.ApplicationConfiguration.MessageContext.Factory.AddEncodeableTypes(typeof(Quickstarts.DataTypes.Types.Namespaces).Assembly); // check the application certificate. application.CheckApplicationInstanceCertificate(false, 0); // run the application interactively. Application.Run(new MainForm(application.ApplicationConfiguration)); } catch (Exception e) { ExceptionDlg.Show(application.ApplicationName, e); return; } }