public object Get()

in Win32/PropertyBag.cs [96:108]


        public object Get(string name)
        {
            CheckIfInitialized();
            object value;
            var propbag2 = new PROPBAG2() {Name = name};
            Result error;
            // Gets the property
            var result = nativePropertyBag.Read(1, ref propbag2, IntPtr.Zero, out value, out error);
            if (result.Failure || error.Failure)
                throw new InvalidOperationException(string.Format(System.Globalization.CultureInfo.InvariantCulture, "Property with name [{0}] is not valid for this instance", name));
            propbag2.Dispose();
            return value;
        }