internal static Type GetPropertySetType(this System.Reflection.Assembly assembly, Guid fmtid) { foreach (Type type in assembly.GetPropertySetTypes()) { PropertySetAttribute attribute = type.GetPropertySetAttribute(); if (attribute != null) { if (attribute.FormatId.Equals(fmtid)) { return(type); } } } return(null); }