/// <summary>The options form_ load.</summary> /// <param name="sender">The sender.</param> /// <param name="e">The e.</param> private void OptionsForm_Load(object sender, EventArgs e) { var cofigTypes = _services.GetConfigurationObjectTypes(); // build a list of config instances foreach (Type cofigType in cofigTypes) { _configurationObjects.Add(_services.Resolve <IConfigurationObject>(cofigType.FullName)); } // add the config editors to the list and watch them for changes foreach (var configObject in _configurationObjects) { configObject.PropertyChanged += ConfigObjectPropertyChanged; lstSettingsProviders.Items.Add(configObject.Name); } // select first if (lstSettingsProviders.Items.Count > 0) { lstSettingsProviders.SelectedIndex = 0; } }