private RemoteControlServiceMux()
        {
            string asmPath = Assembly.GetExecutingAssembly().Location;
            string folder  = Path.GetDirectoryName(asmPath);
            string cfgPath = Path.Combine(folder, "RCCService.Config");

            Logger.LogInfo("Attempt to read config file from {0} ...", cfgPath);
            _config.ReadXml(cfgPath);
            Logger.LogInfo("Config file read, creating service pins ...");
        }
예제 #2
0
        private void tsmiImportReplace_Click(object sender, EventArgs e)
        {
            OPMOpenFileDialog dlg = new OPMOpenFileDialog();

            dlg.InitialDirectory = Path.Combine(Environment.CurrentDirectory, "Templates\\RemoteControl");
            dlg.Filter           = Translator.Translate("TXT_CONFIG_FILES_FILTER");
            dlg.Title            = Translator.Translate("TXT_IMPORT_FULL");

            if (dlg.ShowDialog() == DialogResult.OK)
            {
                _config = new RCCServiceConfig();
                _config.ReadXml(dlg.FileName);
                _config.AcceptChanges();

                DisplayRemotes(true);
            }
        }
예제 #3
0
        private void ReadFromFile()
        {
            string asmPath = Assembly.GetExecutingAssembly().Location;
            string folder  = Path.GetDirectoryName(asmPath);

            _cfgPath = Path.Combine(folder, "RCCService.Config");

            _config = new RCCServiceConfig();
            _config.ReadXml(_cfgPath);

            _config.AcceptChanges();



            DisplayRemotes(false);
            BringToFront();
        }
예제 #4
0
        private void tsmiImportReplace_Click(object sender, EventArgs e)
        {
            OPMOpenFileDialog dlg = new OPMOpenFileDialog();
            dlg.InitialDirectory = Path.Combine(Environment.CurrentDirectory, "Templates\\RemoteControl");
            dlg.Filter = Translator.Translate("TXT_CONFIG_FILES_FILTER");
            dlg.Title = Translator.Translate("TXT_IMPORT_FULL");

            if (dlg.ShowDialog() == DialogResult.OK)
            {
                _config = new RCCServiceConfig();
                _config.ReadXml(dlg.FileName);
                _config.AcceptChanges();

                DisplayRemotes(true);
            }
        }
예제 #5
0
        private void ReadFromFile()
        {
            string asmPath = Assembly.GetExecutingAssembly().Location;
            string folder = Path.GetDirectoryName(asmPath);
            _cfgPath = Path.Combine(folder, "RCCService.Config");

            _config = new RCCServiceConfig();
            _config.ReadXml(_cfgPath);

            _config.AcceptChanges();

            

            DisplayRemotes(false);
            BringToFront();
        }