Example #1
0
        public MainForm()
        {
            InitializeComponent();
            InitTexts();

            try
            {
                List <string> args = Environment.GetCommandLineArgs().ToList();
                setupFlowLayoutPanel.Visible = (args[1] == "SETUPMODE");
            }
            catch
            {
                setupFlowLayoutPanel.Visible = false;
            }


            Text = TextsParams.ParameterName(0);
            serialPort.LoadSettingsFromFile("Comset.xml");
            CreateChildForms();
            systemConfiguration.LoadFromFile("SysType.xml");
            InitSystemConfig();
            EnableAllButtons(false);
            serialPort.PortClosed           += new EventHandler(serialPort_PortClosed);
            serialPort.SerialPortError      += new EventHandler(serialPort_SerialPortError);
            serialPort.FatalSerialPortError += new EventHandler(serialPort_FatalSerialPortError);
        }