private ConfigurationProperty GetProperty(string propertyName)
 {
     if (!propertiesCollection.Contains(propertyName))
     {
         return(null);
     }
     return(propertiesCollection[propertyName]);
 }
Example #2
0
        private bool SetProperty(string name, string value)
        {
            ConfigurationProperty property = null;

            if (_properties.Contains(name))
            {
                property = _properties[name];
            }
            else
            {
                property = new ConfigurationProperty(name, typeof(string), null);

                _properties.Add(property);
            }

            if (property != null)
            {
                base[property] = value;

                return(true);
            }

            return(false);
        }