Ejemplo n.º 1
0
 public override void SetPropertyValues(SettingsContext context, SettingsPropertyValueCollection collection)
 {
     if (_localFileSettingProvider != null)
     {
         _localFileSettingProvider.SetPropertyValues(context, collection);
     }
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Sets the values of the specified group of property settings.
        /// </summary>
        /// <param name="context">A <c>System.Configuration.SettingsContext</c> that describes where the application settings property is used.</param>
        /// <param name="values">A <c>System.Configuration.SettingsPropertyValueCollection</c> representing the group of property settings to set.</param>
        /// <exception cref="System.Configuration.ConfigurationErrorsException">
        /// A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
        /// -or-
        /// There was a general failure saving the settings to the configuration file.</exception>
        public override void SetPropertyValues(SettingsContext context, SettingsPropertyValueCollection values)
        {
            //Only user scope settings could be saved, so delegating this process to standard LocalFileSettingsProvider:
            var defaultProvider = new LocalFileSettingsProvider();

            defaultProvider.Initialize(ApplicationName, _settingValues);
            defaultProvider.SetPropertyValues(context, values);
        }
 public override void SetPropertyValues(SettingsContext context, SettingsPropertyValueCollection collection)
 {
     _provider.SetPropertyValues(context, collection);
 }