예제 #1
0
        private void btnLoadConfig_Click(object sender, EventArgs e)
        {
            try
            {
                if (cboConfigs.Items.Count == 0)
                {
                    return;
                }

                string name = ConfigUtil.ChangeConfig(m_LoadedConfig, ((ConfigEntries)cboConfigs.SelectedItem), chkBxBackupConfig.Checked);
                initForm();
                //txtBxLoadedConfig.Text = name;
                //List<ConfigEntries> ConfigNames = ConfigUtil.GetAllConfigFilesNames(true);
                //if (ConfigNames != null)
                //{

                //    cboConfigs.DataSource = ConfigNames;
                //    cboConfigs.DisplayMember = "Name";

                //}
                MessageBox.Show("Config file has been changed");
            }
            catch (Exception ex)
            {
                MessageBox.Show("btnLoadConfig\n" + ex.ToString());
            }
        }
예제 #2
0
        private void btnLoadConfig_Click(object sender, EventArgs e)
        {
            try
            {
                if (cboConfigs.Items.Count == 0)
                {
                    return;
                }

                ConfigUtil.ChangeConfig(m_LoadedConfig, ((ConfigEntries)cboConfigs.SelectedItem));


                m_ReloadMonitor.Reload();

                MessageBox.Show("Config file has been changed");
            }
            catch (Exception ex)
            {
                MessageBox.Show("btnLoadConfig\n" + ex.Message);
            }
        }
예제 #3
0
        private void btnLoadConfig_Click(object sender, EventArgs e)
        {
            try
            {
                if (cboConfigs.Items.Count == 0)
                {
                    return;
                }

                string name = ConfigUtil.ChangeConfig(m_LoadedConfig, ((ConfigEntries)cboConfigs.SelectedItem), this.chkBxBackupConfig.Checked);

                initForm(configType);

                m_ReloadMonitor.Reload();

                MessageBox.Show("Config file has been changed");
            }
            catch (Exception ex)
            {
                MessageBox.Show("btnLoadConfig\n" + ex.ToString());
            }
        }