' ########################################################################################
' Microsoft Windows
' File: propsys.inc
' Copyright (c) 2011 Jos? Roca
' Portions Copyright (c) Microsoft Corporation.
' All Rights Reserved.
' THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
' EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
' MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
' ########################################################################################
' ########################################################################################
' Library name: PropSysObjects
' Version: 1.0, Locale ID = 0
' Library GUID: {2CDA3294-6C4F-4020-B161-27C530C81FA6}
' ########################################################################################
#IF NOT %DEF(PBX_propsys_PBI)
#DEFINE PBX_propsys_PBI
%EQUATE `PROPSYS_INC = 1
'/* header files for imported files */
#INCLUDE ONCE "Legacy/COM/ObjIdl.inc"
#INCLUDE ONCE "Legacy/COM/OleIdl.inc"
#INCLUDE ONCE "Legacy/COM/OCIdl.inc"
#INCLUDE ONCE "Legacy/System/ShTypes.inc"
#INCLUDE ONCE "Legacy/System/structuredquerycondition.inc"
'#INCLUDE ONCE "propkeydef.inc"
$LIBID_PropSysObjectse = GUID$("{2cda3294-6c4f-4020-b161-27c530c81fa6}") ' // not registered
' ========================================================================================
' ClsIDs (Class identifiers)
' ========================================================================================
$CLSID_InMemoryPropertyStore = GUID$("{9A02E012-6303-4E1E-B9A1-630F802592C5}")
$CLSID_PropertySystem = GUID$("{B8967F85-58AE-4F46-9FB2-5D7904798F4B}")
' ========================================================================================
' IIDs (Interface identifiers)
' ========================================================================================
$IID_IInitializeWithFile = GUID$("{B7D14566-0509-4CCE-A71F-0A554233BD9B}")
$IID_IInitializeWithStream = GUID$("{B824B49D-22AC-4161-AC8A-9916E8FA3F7F}")
$IID_IPropertyStore = GUID$("{886D8EEB-8CF2-4446-8D02-CDBA1DBDCF99}")
$IID_INamedPropertyStore = GUID$("{71604B0F-97B0-4764-8577-2F13E98A1422}")
$IID_IObjectWithPropertyKey = GUID$("{FC0CA0A7-C316-4FD2-9031-3E628E6D4F23}")
$IID_IPropertyChange = GUID$("{F917BC8A-1BBA-4478-A245-1BDE03EB9431}")
$IID_IPropertyChangeArray = GUID$("{380F5CAD-1B5E-42F2-805D-637FD392D31E}")
$IID_IPropertyStoreCapabilities = GUID$("{C8E2D566-186E-4D49-BF41-6909EAD56ACC}")
$IID_IPropertyStoreCache = GUID$("{3017056D-9A91-4E90-937D-746C72ABBF4F}")
$IID_IPropertyEnumType = GUID$("{11E1FBF9-2D56-4A6B-8DB3-7CD193A471F2}")
$IID_IPropertyEnumType2 = GUID$("{9b6e051c-5ddd-4321-9070-fe2acb55e794}")
$IID_IPropertyEnumTypeList = GUID$("{A99400F4-3D84-4557-94BA-1242FB2CC9A6}")
$IID_IPropertyDescription = GUID$("{6F79D558-3E96-4549-A1D1-7D75D2288814}")
$IID_IPropertyDescription2 = GUID$("{57d2eded-5062-400e-b107-5dae79fe57a6}")
$IID_IPropertyDescriptionAliasInfo = GUID$("{F67104FC-2AF9-46FD-B32D-243C1404F3D1}")
$IID_IPropertyDescriptionSearchInfo = GUID$("{078F91BD-29A2-440F-924E-46A291524520}")
$IID_IPropertyDescriptionRelatedPropertyInfo = GUID$("{507393f4-2a3d-4a60-b59e-d9c75716c2dd}")
$IID_IPropertySystem = GUID$("{CA724E8A-C3E6-442B-88A4-6FB0DB8035A3}")
$IID_IPropertyDescriptionList = GUID$("{1F9FC1D0-C39B-4B26-817F-011967D3440E}")
$IID_IPropertyStoreFactory = GUID$("{BC110B6D-57E8-4148-A9C6-91015AB2F3A5}")
$IID_IDelayedPropertyStoreFactory = GUID$("{40D4577F-E237-4BDB-BD69-58F089431B6A}")
$IID_IPersistSerializedPropStorage = GUID$("{E318AD57-0AA0-450F-ACA5-6FAB7103D917}")
$IID_IPersistSerializedPropStorage2 = GUID$("{77effa68-4f98-4366-ba72-573b3d880571}")
$IID_IPropertySystemChangeNotify = GUID$("{FA955FD9-38BE-4879-A6CE-824CF52D609F}")
$IID_ICreateObject = GUID$("{75121952-E0D0-43E5-9380-1D80483ACF72}")
' ########################################################################################
' Interface name = IInitializeWithFile
' IID = B7D14566-0509-4CCE-A71F-0A554233BD9B
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IInitializeWithFile_INTERFACE_DEFINED)
 %IInitializeWithFile_INTERFACE_DEFINED = 1
INTERFACE IInitializeWithFile $IID_IInitializeWithFile
 INHERIT IUnknown
 ' =====================================================================================
 METHOD OnDeviceStateChanged ( ' VTable offset = 12
 BYREF pszFilePath AS WSTRINGZ
 , BYVAL grfMode AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IInitializeWithFile_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IInitializeWithStream
' IID = B824B49D-22AC-4161-AC8A-9916E8FA3F7F
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IInitializeWithStream_INTERFACE_DEFINED)
 %IInitializeWithStream_INTERFACE_DEFINED = 1
INTERFACE IInitializeWithStream $IID_IInitializeWithStream
 INHERIT IUnknown
 ' =====================================================================================
 METHOD Initialize ( ' VTable offset = 12
 BYVAL pstream AS IStream
 , BYVAL grfMode AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IInitializeWithStream_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyStore
' IID = 886D8EEB-8CF2-4446-8D02-CDBA1DBDCF99
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyStore_INTERFACE_DEFINED)
 %IPropertyStore_INTERFACE_DEFINED = 1
INTERFACE IPropertyStore $IID_IPropertyStore
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 12
 BYREF cProps AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAt ( ' VTable offset = 16
 BYVAL iProp AS DWORD
 , BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetValue ( ' VTable offset = 20
 BYREF key AS PROPERTYKEY
 , BYREF pv AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD SetValue ( ' VTable offset = 24
 BYREF key AS PROPERTYKEY
 , BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD Commit ( ' VTable offset = 28
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyStore_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = INamedPropertyStore
' IID = 71604B0F-97B0-4764-8577-2F13E98A1422
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%INamedPropertyStore_INTERFACE_DEFINED)
 %INamedPropertyStore_INTERFACE_DEFINED = 1
INTERFACE INamedPropertyStore $IID_INamedPropertyStore
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetNamedValue ( ' VTable offset = 12
 BYREF pszName AS WSTRINGZ
 , BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD SetNamedValue ( ' VTable offset = 16
 BYREF pszName AS WSTRINGZ
 , BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetNameCount ( ' VTable offset = 20
 BYREF pdwCount AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetNameAt ( ' VTable offset = 24
 BYVAL iProp AS DWORD
 , BYREF pbstrName AS WSTRING
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __INamedPropertyStore_INTERFACE_DEFINED__ */
' enum GETPROPERTYSTOREFLAGS
%EQUATE `GPS_DEFAULT = 0&
%EQUATE `GPS_HANDLERPROPERTIESONLY = &H1&
%EQUATE `GPS_READWRITE = &H2&
%EQUATE `GPS_TEMPORARY = &H4&
%EQUATE `GPS_FASTPROPERTIESONLY = &H8&
%EQUATE `GPS_OPENSLOWITEM = &H10&
%EQUATE `GPS_DELAYCREATION = &H20&
%EQUATE `GPS_BESTEFFORT = &H40&
%EQUATE `GPS_NO_OPLOCK = &H80&
%EQUATE `GPS_MASK_VALID = &Hff&
' ########################################################################################
' Interface name = IObjectWithPropertyKey
' IID = FC0CA0A7-C316-4FD2-9031-3E628E6D4F23
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IObjectWithPropertyKey_INTERFACE_DEFINED)
 %IObjectWithPropertyKey_INTERFACE_DEFINED = 1
INTERFACE IObjectWithPropertyKey $IID_IObjectWithPropertyKey
 INHERIT IUnknown
 ' =====================================================================================
 METHOD SetPropertyKey ( ' VTable offset = 12
 BYREF key AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 16
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IObjectWithPropertyKey_INTERFACE_DEFINED__ */
' enum PKA_FLAGS
%EQUATE `PKA_SET = 0
%EQUATE `PKA_APPEND = %PKA_SET + 1
%EQUATE `PKA_DELETE = %PKA_APPEND + 1
' ########################################################################################
' Interface name = IPropertyChange
' IID = F917BC8A-1BBA-4478-A245-1BDE03EB9431
' Inherited interface = IObjectWithPropertyKey
' ########################################################################################
#IF NOT %DEF(%IPropertyChange_INTERFACE_DEFINED)
 %IPropertyChange_INTERFACE_DEFINED = 1
INTERFACE IPropertyChange $IID_IPropertyChange
 INHERIT IUnknown
 ' =====================================================================================
 ' IObjectWithPropertyKey methods
 ' =====================================================================================
 METHOD SetPropertyKey ( ' VTable offset = 12
 BYREF key AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 16
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyChange method
 ' =====================================================================================
 METHOD ApplyToPropVariant ( ' VTable offset = 20
 BYREF propvarIn AS PROPVARIANT
 , BYREF ppropvarOut AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyChange_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyChangeArray
' IID = 380F5CAD-1B5E-42F2-805D-637FD392D31E
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyChangeArray_INTERFACE_DEFINED)
 %IPropertyChangeArray_INTERFACE_DEFINED = 1
INTERFACE IPropertyChangeArray $IID_IPropertyChangeArray
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 12
 BYREF pcOperations AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAt ( ' VTable offset = 16
 BYVAL iIndex AS DWORD
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD InsertAt ( ' VTable offset = 20
 BYVAL iIndex AS DWORD
 , BYVAL ppropChange AS IPropertyChange
 ) AS LONG
 ' =====================================================================================
 METHOD Append ( ' VTable offset = 24
 BYVAL ppropChange AS IPropertyChange
 ) AS LONG
 ' =====================================================================================
 METHOD AppendOrReplace ( ' VTable offset = 28
 BYVAL ppropChange AS IPropertyChange
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveAt ( ' VTable offset = 32
 BYVAL iIndex AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD IsKeyInArray ( ' VTable offset = 36
 BYREF key AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyChangeArray_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyStoreCapabilities
' IID = C8E2D566-186E-4D49-BF41-6909EAD56ACC
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyStoreCapabilities_INTERFACE_DEFINED)
 %IPropertyStoreCapabilities_INTERFACE_DEFINED = 1
INTERFACE IPropertyStoreCapabilities $IID_IPropertyStoreCapabilities
 INHERIT IUnknown
 ' =====================================================================================
 METHOD IsPropertyWritable ( ' VTable offset = 12
 BYREF key AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyStoreCapabilities_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyStoreCache
' IID = 3017056D-9A91-4E90-937D-746C72ABBF4F
' Inherited interface = IPropertyStore
' ########################################################################################
#IF NOT %DEF(%IPropertyStoreCache_INTERFACE_DEFINED)
 %IPropertyStoreCache_INTERFACE_DEFINED = 1
' enum PSC_STATE
%EQUATE `PSC_NORMAL = 0
%EQUATE `PSC_NOTINSOURCE = 1
%EQUATE `PSC_DIRTY = 2
%EQUATE `PSC_READONLY = 3
INTERFACE IPropertyStoreCache $IID_IPropertyStoreCache
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyStore methods
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 12
 BYREF cProps AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAt ( ' VTable offset = 16
 BYVAL iProp AS DWORD
 , BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetValue ( ' VTable offset = 20
 BYREF key AS PROPERTYKEY
 , BYREF pv AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD SetValue ( ' VTable offset = 24
 BYREF key AS PROPERTYKEY
 , BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD Commit ( ' VTable offset = 28
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyStoreCache methods
 ' =====================================================================================
 METHOD GetState ( ' VTable offset = 32
 BYREF key AS PROPERTYKEY
 , BYREF pstate AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetValueAndState ( ' VTable offset = 36
 BYREF key AS PROPERTYKEY
 , BYREF ppropvar AS PROPVARIANT
 , BYREF pstate AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD SetState ( ' VTable offset = 40
 BYREF key AS PROPERTYKEY
 , BYVAL state AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD SetValueAndState ( ' VTable offset = 44
 BYREF key AS PROPERTYKEY
 , BYREF ppropvar AS PROPVARIANT
 , BYVAL state AS LONG
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyStoreCache_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyEnumType
' IID = 11E1FBF9-2D56-4A6B-8DB3-7CD193A471F2
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyEnumType_INTERFACE_DEFINED)
 %IPropertyEnumType_INTERFACE_DEFINED = 1
' enum PROPENUMTYPE
%EQUATE `PET_DISCRETEVALUE = 0
%EQUATE `PET_RANGEDVALUE = 1
%EQUATE `PET_DEFAULTVALUE = 2
%EQUATE `PET_ENDRANGE = 3
INTERFACE IPropertyEnumType $IID_IPropertyEnumType
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetEnumType ( ' VTable offset = 12
 BYREF penumtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetValue ( ' VTable offset = 16
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetRangeMinValue ( ' VTable offset = 20
 BYREF ppropvarMin AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetRangeSetValue ( ' VTable offset = 24
 BYREF ppropvarSet AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayText ( ' VTable offset = 28
 BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyEnumType_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyEnumType2
' IID = 9b6e051c-5ddd-4321-9070-fe2acb55e794
' Inherited interface = IPropertyEnumType
' ########################################################################################
#IF NOT %DEF(%IPropertyEnumType2_INTERFACE_DEFINED)
 %IPropertyEnumType2_INTERFACE_DEFINED = 1
INTERFACE IPropertyEnumType2 $IID_IPropertyEnumType2
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyEnumType methods
 ' =====================================================================================
 METHOD GetEnumType ( ' VTable offset = 12
 BYREF penumtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetValue ( ' VTable offset = 16
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetRangeMinValue ( ' VTable offset = 20
 BYREF ppropvarMin AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetRangeSetValue ( ' VTable offset = 24
 BYREF ppropvarSet AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayText ( ' VTable offset = 28
 BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyEnumType2 methods
 ' =====================================================================================
 METHOD GetImageReference ( ' VTable offset = 32
 BYREF ppszImageRes AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyEnumType2_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyEnumTypeList
' IID = A99400F4-3D84-4557-94BA-1242FB2CC9A6
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyEnumTypeList_INTERFACE_DEFINED)
 %IPropertyEnumTypeList_INTERFACE_DEFINED= 1
INTERFACE IPropertyEnumTypeList $IID_IPropertyEnumTypeList
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 12
 BYREF pctypes AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAt ( ' VTable offset = 16
 BYVAL itype AS DWORD
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD GetConditionAt ( ' VTable offset = 20
 BYVAL nIndex AS DWORD
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD FindMatchingIndex ( ' VTable offset = 24
 BYREF propvarCmp AS PROPVARIANT
 , BYREF pnIndex AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyEnumTypeList_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyDescription
' IID = 6F79D558-3E96-4549-A1D1-7D75D2288814
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyDescription_INTERFACE_DEFINED)
 %IPropertyDescription_INTERFACE_DEFINED = 1
' enum PROPDESC_TYPE_FLAGS
%EQUATE `PDTF_DEFAULT = 0&
%EQUATE `PDTF_MULTIPLEVALUES = &H1&
%EQUATE `PDTF_ISINNATE = &H2&
%EQUATE `PDTF_ISGROUP = &H4&
%EQUATE `PDTF_CANGROUPBY = &H8&
%EQUATE `PDTF_CANSTACKBY = &H10&
%EQUATE `PDTF_ISTREEPROPERTY = &H20&
%EQUATE `PDTF_INCLUDEINFULLTEXTQUERY = &H40&
%EQUATE `PDTF_ISVIEWABLE = &H80&
%EQUATE `PDTF_ISQUERYABLE = &H100&
%EQUATE `PDTF_CANBEPURGED = &H200
%EQUATE `PDTF_SEARCHRAWVALUE = &H400&
%EQUATE `PDTF_ISSYSTEMPROPERTY = &H80000000&
%EQUATE `PDTF_MASK_ALL = &H800007ff&
' enum PROPDESC_VIEW_FLAGS
%EQUATE `PDVF_DEFAULT = 0&
%EQUATE `PDVF_CENTERALIGN = &H1&
%EQUATE `PDVF_RIGHTALIGN = &H2&
%EQUATE `PDVF_BEGINNEWGROUP = &H4&
%EQUATE `PDVF_FILLAREA = &H8&
%EQUATE `PDVF_SORTDESCENDING = &H10&
%EQUATE `PDVF_SHOWONLYIFPRESENT = &H20&
%EQUATE `PDVF_SHOWBYDEFAULT = &H40&
%EQUATE `PDVF_SHOWINPRIMARYLIST = &H80&
%EQUATE `PDVF_SHOWINSECONDARYLIST = &H100&
%EQUATE `PDVF_HIDELABEL = &H200&
%EQUATE `PDVF_HIDDEN = &H800&
%EQUATE `PDVF_CANWRAP = &H1000&
%EQUATE `PDVF_MASK_ALL = &H1bff&
' enum PROPDESC_DISPLAYTYPE
%EQUATE `PDDT_STRING = 0
%EQUATE `PDDT_NUMBER = 1
%EQUATE `PDDT_BOOLEAN = 2
%EQUATE `PDDT_DATETIME = 3
%EQUATE `PDDT_ENUMERATED = 4
' enum PROPDESC_GROUPING_RANGE
%EQUATE `PDGR_DISCRETE = 0
%EQUATE `PDGR_ALPHANUMERIC = 1
%EQUATE `PDGR_SIZE = 2
%EQUATE `PDGR_DYNAMIC = 3
%EQUATE `PDGR_DATE = 4
%EQUATE `PDGR_PERCENT = 5
%EQUATE `PDGR_ENUMERATED = 6
' enum PROPDESC_FORMAT_FLAGS
%EQUATE `PDFF_DEFAULT = 0&
%EQUATE `PDFF_PREFIXNAME = &H1&
%EQUATE `PDFF_FILENAME = &H2&
%EQUATE `PDFF_ALWAYSKB = &H4&
%EQUATE `PDFF_RESERVED_RIGHTTOLEFT = &H8&
%EQUATE `PDFF_SHORTTIME = &H10&
%EQUATE `PDFF_LONGTIME = &H20&
%EQUATE `PDFF_HIDETIME = &H40&
%EQUATE `PDFF_SHORTDATE = &H80&
%EQUATE `PDFF_LONGDATE = &H100&
%EQUATE `PDFF_HIDEDATE = &H200&
%EQUATE `PDFF_RELATIVEDATE = &H400&
%EQUATE `PDFF_USEEDITINVITATION = &H800&
%EQUATE `PDFF_READONLY = &H1000&
%EQUATE `PDFF_NOAUTOREADINGORDER = &H2000&
' enum PROPDESC_SORTDESCRIPTION
%EQUATE `PDSD_GENERAL = 0
%EQUATE `PDSD_A_Z = 1
%EQUATE `PDSD_LOWEST_HIGHEST = 2
%EQUATE `PDSD_SMALLEST_BIGGEST = 3
%EQUATE `PDSD_OLDEST_NEWEST = 4
' enum PROPDESC_RELATIVEDESCRIPTION_TYPE
%EQUATE `PDRDT_GENERAL = 0
%EQUATE `PDRDT_DATE = 1
%EQUATE `PDRDT_SIZE = 2
%EQUATE `PDRDT_COUNT = 3
%EQUATE `PDRDT_REVISION = 4
%EQUATE `PDRDT_LENGTH = 5
%EQUATE `PDRDT_DURATION = 6
%EQUATE `PDRDT_SPEED = 7
%EQUATE `PDRDT_RATE = 8
%EQUATE `PDRDT_RATING = 9
%EQUATE `PDRDT_PRIORITY = 10
' enum PROPDESC_AGGREGATION_TYPE
%EQUATE `PDAT_DEFAULT = 0
%EQUATE `PDAT_FIRST = 1
%EQUATE `PDAT_SUM = 2
%EQUATE `PDAT_AVERAGE = 3
%EQUATE `PDAT_DATERANGE = 4
%EQUATE `PDAT_UNION = 5
%EQUATE `PDAT_MAX = 6
%EQUATE `PDAT_MIN = 7
' enum PROPDESC_CONDITION_TYPE
%EQUATE `PDCOT_NONE = 0
%EQUATE `PDCOT_STRING = 1
%EQUATE `PDCOT_SIZE = 2
%EQUATE `PDCOT_DATETIME = 3
%EQUATE `PDCOT_BOOLEAN = 4
%EQUATE `PDCOT_NUMBER = 5
INTERFACE IPropertyDescription $IID_IPropertyDescription
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 12
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetCanonicalName ( ' VTable offset = 16
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyType ( ' VTable offset = 20
 BYREF pvartype AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayName ( ' VTable offset = 24
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetEditInvitation ( ' VTable offset = 28
 BYREF ppszInvite AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetTypeFlags ( ' VTable offset = 32
 BYVAL mask AS LONG
 , BYREF ppdtFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetViewFlags ( ' VTable offset = 36
 BYREF ppdvFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetDefaultColumnWidth ( ' VTable offset = 40
 BYREF pcxChars AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayType ( ' VTable offset = 44
 BYREF pdisplaytype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetColumnState ( ' VTable offset = 48
 BYREF pcsFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetGroupingRange ( ' VTable offset = 48
 BYREF pgr AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescriptionType ( ' VTable offset = 52
 BYREF prdt AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescription ( ' VTable offset = 56
 BYREF propvar1 AS PROPVARIANT
 , BYREF propvar2 AS PROPVARIANT
 , BYREF ppszDesc1 AS DWORD
 , BYREF ppszDesc2 AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescription ( ' VTable offset = 60
 BYREF psd AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescriptionLabel ( ' VTable offset = 64
 BYVAL fDescending AS LONG
 , BYREF ppszDescription AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAggregationType ( ' VTable offset = 68
 BYREF paggtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetConditionType ( ' VTable offset = 72
 BYREF pcontype AS LONG
 , BYREF popDefault AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetEnumTypeList ( ' VTable offset = 76
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD CoerceToCanonicalValue ( ' VTable offset = 80
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplay ( ' VTable offset = 84
 BYREF propvar AS PROPVARIANT
 , BYVAL pdfFlags AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD IsValueCanonical ( ' VTable offset = 88
 BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyDescription_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyDescription2
' IID = 57d2eded-5062-400e-b107-5dae79fe57a6
' Inherited interface = IPropertyDescription
' ########################################################################################
#IF NOT %DEF(%IPropertyDescription2_INTERFACE_DEFINED)
 %IPropertyDescription2_INTERFACE_DEFINED = 1
INTERFACE IPropertyDescription2 $IID_IPropertyDescription2
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyDescription methods
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 12
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetCanonicalName ( ' VTable offset = 16
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyType ( ' VTable offset = 20
 BYREF pvartype AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayName ( ' VTable offset = 24
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetEditInvitation ( ' VTable offset = 28
 BYREF ppszInvite AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetTypeFlags ( ' VTable offset = 32
 BYVAL mask AS LONG
 , BYREF ppdtFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetViewFlags ( ' VTable offset = 36
 BYREF ppdvFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetDefaultColumnWidth ( ' VTable offset = 40
 BYREF pcxChars AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayType ( ' VTable offset = 44
 BYREF pdisplaytype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetColumnState ( ' VTable offset = 48
 BYREF pcsFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetGroupingRange ( ' VTable offset = 48
 BYREF pgr AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescriptionType ( ' VTable offset = 52
 BYREF prdt AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescription ( ' VTable offset = 56
 BYREF propvar1 AS PROPVARIANT
 , BYREF propvar2 AS PROPVARIANT
 , BYREF ppszDesc1 AS DWORD
 , BYREF ppszDesc2 AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescription ( ' VTable offset = 60
 BYREF psd AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescriptionLabel ( ' VTable offset = 64
 BYVAL fDescending AS LONG
 , BYREF ppszDescription AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAggregationType ( ' VTable offset = 68
 BYREF paggtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetConditionType ( ' VTable offset = 72
 BYREF pcontype AS LONG
 , BYREF popDefault AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetEnumTypeList ( ' VTable offset = 76
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD CoerceToCanonicalValue ( ' VTable offset = 80
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplay ( ' VTable offset = 84
 BYREF propvar AS PROPVARIANT
 , BYVAL pdfFlags AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD IsValueCanonical ( ' VTable offset = 88
 BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyDescription2 methods
 ' =====================================================================================
 METHOD GetImageReferenceForValue ( ' VTable offset = 92
 BYREF propvar AS PROPVARIANT
 , BYREF ppszImageRes AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyDescription2_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyDescriptionAliasInfo
' IID = F67104FC-2AF9-46FD-B32D-243C1404F3D1
' Inherited interface = IPropertyDescription
' ########################################################################################
#IF NOT %DEF(%IPropertyDescriptionAliasInfo_INTERFACE_DEFINED)
 %IPropertyDescriptionAliasInfo_INTERFACE_DEFINED = 1
INTERFACE IPropertyDescriptionAliasInfo $IID_IPropertyDescriptionAliasInfo
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyDescription methods
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 12
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetCanonicalName ( ' VTable offset = 16
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyType ( ' VTable offset = 20
 BYREF pvartype AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayName ( ' VTable offset = 24
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetEditInvitation ( ' VTable offset = 28
 BYREF ppszInvite AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetTypeFlags ( ' VTable offset = 32
 BYVAL mask AS LONG
 , BYREF ppdtFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetViewFlags ( ' VTable offset = 36
 BYREF ppdvFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetDefaultColumnWidth ( ' VTable offset = 40
 BYREF pcxChars AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayType ( ' VTable offset = 44
 BYREF pdisplaytype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetColumnState ( ' VTable offset = 48
 BYREF pcsFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetGroupingRange ( ' VTable offset = 48
 BYREF pgr AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescriptionType ( ' VTable offset = 52
 BYREF prdt AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescription ( ' VTable offset = 56
 BYREF propvar1 AS PROPVARIANT
 , BYREF propvar2 AS PROPVARIANT
 , BYREF ppszDesc1 AS DWORD
 , BYREF ppszDesc2 AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescription ( ' VTable offset = 60
 BYREF psd AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescriptionLabel ( ' VTable offset = 64
 BYVAL fDescending AS LONG
 , BYREF ppszDescription AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAggregationType ( ' VTable offset = 68
 BYREF paggtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetConditionType ( ' VTable offset = 72
 BYREF pcontype AS LONG
 , BYREF popDefault AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetEnumTypeList ( ' VTable offset = 76
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD CoerceToCanonicalValue ( ' VTable offset = 80
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplay ( ' VTable offset = 84
 BYREF propvar AS PROPVARIANT
 , BYVAL pdfFlags AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD IsValueCanonical ( ' VTable offset = 88
 BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyDescriptionAliasInfo methods
 ' =====================================================================================
 METHOD GetSortByAlias ( ' VTable offset = 92
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD GetAdditionalSortByAliases ( ' VTable offset = 96
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyDescriptionAliasInfo_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyDescriptionSearchInfo
' IID = 078F91BD-29A2-440F-924E-46A291524520
' Inherited interface = IPropertyDescription
' ########################################################################################
#IF NOT %DEF(%IPropertyDescriptionSearchInfo_INTERFACE_DEFINED)
 %IPropertyDescriptionSearchInfo_INTERFACE_DEFINED = 1
' enum PROPDESC_SEARCHINFO_FLAGS
%EQUATE `PDSIF_DEFAULT = 0&
%EQUATE `PDSIF_ININVERTEDINDEX = &H1&
%EQUATE `PDSIF_ISCOLUMN = &H2&
%EQUATE `PDSIF_ISCOLUMNSPARSE = &H4&
%EQUATE `PDSIF_ALWAYSINCLUDE = &H8&
' enum PROPDESC_COLUMNINDEX_TYPE
%EQUATE `PDCIT_NONE = 0
%EQUATE `PDCIT_ONDISK = 1
%EQUATE `PDCIT_INMEMORY = 2
%EQUATE `PDCIT_ONDEMAND = 3
%EQUATE `PDCIT_ONDISKALL = 4
%EQUATE `PDCIT_ONDISKVECTOR = 5
INTERFACE IPropertyDescriptionSearchInfo $IID_IPropertyDescriptionSearchInfo
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyDescription methods
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 12
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetCanonicalName ( ' VTable offset = 16
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyType ( ' VTable offset = 20
 BYREF pvartype AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayName ( ' VTable offset = 24
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetEditInvitation ( ' VTable offset = 28
 BYREF ppszInvite AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetTypeFlags ( ' VTable offset = 32
 BYVAL mask AS LONG
 , BYREF ppdtFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetViewFlags ( ' VTable offset = 36
 BYREF ppdvFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetDefaultColumnWidth ( ' VTable offset = 40
 BYREF pcxChars AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayType ( ' VTable offset = 44
 BYREF pdisplaytype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetColumnState ( ' VTable offset = 48
 BYREF pcsFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetGroupingRange ( ' VTable offset = 48
 BYREF pgr AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescriptionType ( ' VTable offset = 52
 BYREF prdt AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescription ( ' VTable offset = 56
 BYREF propvar1 AS PROPVARIANT
 , BYREF propvar2 AS PROPVARIANT
 , BYREF ppszDesc1 AS DWORD
 , BYREF ppszDesc2 AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescription ( ' VTable offset = 60
 BYREF psd AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescriptionLabel ( ' VTable offset = 64
 BYVAL fDescending AS LONG
 , BYREF ppszDescription AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAggregationType ( ' VTable offset = 68
 BYREF paggtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetConditionType ( ' VTable offset = 72
 BYREF pcontype AS LONG
 , BYREF popDefault AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetEnumTypeList ( ' VTable offset = 76
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD CoerceToCanonicalValue ( ' VTable offset = 80
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplay ( ' VTable offset = 84
 BYREF propvar AS PROPVARIANT
 , BYVAL pdfFlags AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD IsValueCanonical ( ' VTable offset = 88
 BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyDescriptionSearchInfo methods
 ' =====================================================================================
 METHOD GetSearchInfoFlags ( ' VTable offset = 92
 BYREF ppdsiFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetColumnIndexType ( ' VTable offset = 96
 BYREF ppdciType AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetProjectionString ( ' VTable offset = 100
 BYREF ppszProjection AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetMaxSize ( ' VTable offset = 104
 BYREF pcbMaxSize AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyDescriptionSearchInfo_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyDescriptionRelatedPropertyInfo
' IID = 507393f4-2a3d-4a60-b59e-d9c75716c2dd
' Inherited interface = IPropertyDescription
' ########################################################################################
#IF NOT %DEF(%IPropertyDescriptionRelatedPropertyInfo_INTERFACE_DEFINED)
 %IPropertyDescriptionRelatedPropertyInfo_INTERFACE_DEFINED = 1
INTERFACE IPropertyDescriptionRelatedPropertyInfo $IID_IPropertyDescriptionRelatedPropertyInfo
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyDescription methods
 ' =====================================================================================
 METHOD GetPropertyKey ( ' VTable offset = 12
 BYREF pkey AS PROPERTYKEY
 ) AS LONG
 ' =====================================================================================
 METHOD GetCanonicalName ( ' VTable offset = 16
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyType ( ' VTable offset = 20
 BYREF pvartype AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayName ( ' VTable offset = 24
 BYREF ppszName AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetEditInvitation ( ' VTable offset = 28
 BYREF ppszInvite AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetTypeFlags ( ' VTable offset = 32
 BYVAL mask AS LONG
 , BYREF ppdtFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetViewFlags ( ' VTable offset = 36
 BYREF ppdvFlags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetDefaultColumnWidth ( ' VTable offset = 40
 BYREF pcxChars AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDisplayType ( ' VTable offset = 44
 BYREF pdisplaytype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetColumnState ( ' VTable offset = 48
 BYREF pcsFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetGroupingRange ( ' VTable offset = 48
 BYREF pgr AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescriptionType ( ' VTable offset = 52
 BYREF prdt AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetRelativeDescription ( ' VTable offset = 56
 BYREF propvar1 AS PROPVARIANT
 , BYREF propvar2 AS PROPVARIANT
 , BYREF ppszDesc1 AS DWORD
 , BYREF ppszDesc2 AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescription ( ' VTable offset = 60
 BYREF psd AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetSortDescriptionLabel ( ' VTable offset = 64
 BYVAL fDescending AS LONG
 , BYREF ppszDescription AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAggregationType ( ' VTable offset = 68
 BYREF paggtype AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetConditionType ( ' VTable offset = 72
 BYREF pcontype AS LONG
 , BYREF popDefault AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetEnumTypeList ( ' VTable offset = 76
 BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD CoerceToCanonicalValue ( ' VTable offset = 80
 BYREF ppropvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplay ( ' VTable offset = 84
 BYREF propvar AS PROPVARIANT
 , BYVAL pdfFlags AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD IsValueCanonical ( ' VTable offset = 88
 BYREF propvar AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPropertyDescriptionSearchInfo methods
 ' =====================================================================================
 METHOD GetRelatedProperty ( ' VTable offset = 92
 BYREF pszRelationshipName AS WSTRINGZ
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyDescriptionSearchInfo_INTERFACE_DEFINED__ */
' enum PROPDESC_ENUMFILTER
%EQUATE `PDEF_ALL = 0
%EQUATE `PDEF_SYSTEM = 1
%EQUATE `PDEF_NONSYSTEM = 2
%EQUATE `PDEF_VIEWABLE = 3
%EQUATE `PDEF_QUERYABLE = 4
%EQUATE `PDEF_INFULLTEXTQUERY = 5
%EQUATE `PDEF_COLUMN = 6
' ########################################################################################
' Interface name = IPropertySystem
' IID = CA724E8A-C3E6-442B-88A4-6FB0DB8035A3
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertySystem_INTERFACE_DEFINED)
 %IPropertySystem_INTERFACE_DEFINED = 1
INTERFACE IPropertySystem $IID_IPropertySystem
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetPropertyDescription ( ' VTable offset = 12
 BYREF propkey AS PROPERTYKEY
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyDescriptionByName ( ' VTable offset = 16
 BYREF pszCanonicalName AS WSTRINGZ
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyDescriptionListFromString ( ' VTable offset = 20
 BYREF pszPropList AS WSTRINGZ
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD EnumeratePropertyDescriptions ( ' VTable offset = 24
 BYVAL filterOn AS LONG
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplay ( ' VTable offset = 28
 BYREF key AS PROPERTYKEY
 , BYREF propvar AS PROPVARIANT
 , BYVAL pdff AS LONG
 , BYREF pszText AS WSTRINGZ
 , BYREF cchText AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD FormatForDisplayAlloc ( ' VTable offset = 32
 BYREF key AS PROPERTYKEY
 , BYREF propvar AS PROPVARIANT
 , BYVAL pdff AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD RegisterPropertySchema ( ' VTable offset = 36
 BYREF pszPath AS WSTRINGZ
 ) AS LONG
 ' =====================================================================================
 METHOD UnregisterPropertySchema ( ' VTable offset = 40
 BYREF pszPath AS WSTRINGZ
 ) AS LONG
 ' =====================================================================================
 METHOD RefreshPropertySchema ( ' VTable offset = 44
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertySystem_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyDescriptionList
' IID = 1F9FC1D0-C39B-4B26-817F-011967D3440E
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyDescriptionList_INTERFACE_DEFINED)
 %IPropertyDescriptionList_INTERFACE_DEFINED = 1
INTERFACE IPropertyDescriptionList $IID_IPropertyDescriptionList
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 12
 BYREF pcElem AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAt ( ' VTable offset = 16
 BYVAL iElem AS DWORD
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyDescriptionList_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertyStoreFactory
' IID = BC110B6D-57E8-4148-A9C6-91015AB2F3A5
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertyStoreFactory_INTERFACE_DEFINED)
 %IPropertyStoreFactory_INTERFACE_DEFINED = 1
INTERFACE IPropertyStoreFactory $IID_IPropertyStoreFactory
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetPropertyStore ( ' VTable offset = 12
 BYVAL flags AS LONG
 , BYVAL pUnkFactory AS IUnknown
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyStoreForKeys ( ' VTable offset = 16
 BYREF rgKeys AS PROPERTYKEY
 , BYVAL cKeys AS DWORD
 , BYVAL flags AS LONG
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertyStoreFactory_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IDelayedPropertyStoreFactory
' IID = 40D4577F-E237-4BDB-BD69-58F089431B6A
' Inherited interface = IPropertyStoreFactory
' ########################################################################################
#IF NOT %DEF(%IDelayedPropertyStoreFactory_INTERFACE_DEFINED)
 %IDelayedPropertyStoreFactory_INTERFACE_DEFINED = 1
INTERFACE IDelayedPropertyStoreFactory $IID_IDelayedPropertyStoreFactory
 INHERIT IUnknown
 ' =====================================================================================
 ' IPropertyStoreFactory methods
 ' =====================================================================================
 METHOD GetPropertyStore ( ' VTable offset = 12
 BYVAL flags AS LONG
 , BYVAL pUnkFactory AS IUnknown
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyStoreForKeys ( ' VTable offset = 16
 BYREF rgKeys AS PROPERTYKEY
 , BYVAL cKeys AS DWORD
 , BYVAL flags AS LONG
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IDelayedPropertyStoreFactory methods
 ' =====================================================================================
 METHOD GetDelayedPropertyStore ( ' VTable offset = 20
 BYVAL flags AS LONG
 , BYVAL dwStoreId AS DWORD
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IDelayedPropertyStoreFactory_INTERFACE_DEFINED__ */
' enum PERSIST_SPROPSTORE_FLAGS
%EQUATE `FPSPS_DEFAULT = 0
%EQUATE `FPSPS_READONLY = &H1
'typedef int PERSIST_SPROPSTORE_FLAGS;
'typedef struct tagSERIALIZEDPROPSTORAGE SERIALIZEDPROPSTORAGE;
'typedef SERIALIZEDPROPSTORAGE __unaligned *PUSERIALIZEDPROPSTORAGE;
'typedef const SERIALIZEDPROPSTORAGE __unaligned *PCUSERIALIZEDPROPSTORAGE;
' ########################################################################################
' Interface name = IPersistSerializedPropStorage
' IID = E318AD57-0AA0-450F-ACA5-6FAB7103D917
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPersistSerializedPropStorage_INTERFACE_DEFINED)
 %IPersistSerializedPropStorage_INTERFACE_DEFINED = 1
INTERFACE IPersistSerializedPropStorage $IID_IPersistSerializedPropStorage
 INHERIT IUnknown
 ' =====================================================================================
 METHOD SetFlags ( ' VTable offset = 12
 BYVAL flags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD SetPropertyStorage ( ' VTable offset = 16
 BYVAL psps AS BYTE PTR
 , BYVAL cb AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyStorage ( ' VTable offset = 20
 BYREF ppsps AS DWORD
 , BYREF pcb AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPersistSerializedPropStorage_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPersistSerializedPropStorage2
' IID = 77effa68-4f98-4366-ba72-573b3d880571
' Inherited interface = IPersistSerializedPropStorage
' ########################################################################################
#IF NOT %DEF(%IPersistSerializedPropStorage2_INTERFACE_DEFINED)
 %IPersistSerializedPropStorage2_INTERFACE_DEFINED = 1
INTERFACE IPersistSerializedPropStorage2 $IID_IPersistSerializedPropStorage2
 INHERIT IUnknown
 ' =====================================================================================
 ' IPersistSerializedPropStorage methods
 ' =====================================================================================
 METHOD SetFlags ( ' VTable offset = 12
 BYVAL flags AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD SetPropertyStorage ( ' VTable offset = 16
 BYVAL psps AS BYTE PTR
 , BYVAL cb AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyStorage ( ' VTable offset = 20
 BYREF ppsps AS DWORD
 , BYREF pcb AS DWORD
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IPersistSerializedPropStorage2 methods
 ' =====================================================================================
 METHOD GetPropertyStorageSize ( ' VTable offset = 24
 BYREF pcb AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPropertyStorageBuffer ( ' VTable offset = 28
 BYREF psps AS DWORD
 , BYVAL cb AS DWORD
 , BYREF pcbWritten AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPersistSerializedPropStorage2_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IPropertySystemChangeNotify
' IID = FA955FD9-38BE-4879-A6CE-824CF52D609F
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IPropertySystemChangeNotify_INTERFACE_DEFINED)
 %IPropertySystemChangeNotify_INTERFACE_DEFINED = 1
INTERFACE IPropertySystemChangeNotify $IID_IPropertySystemChangeNotify
 INHERIT IUnknown
 ' =====================================================================================
 METHOD SchemaRefreshed ( ' VTable offset = 12
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IPropertySystemChangeNotify_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = ICreateObject
' IID = 75121952-E0D0-43E5-9380-1D80483ACF72
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%ICreateObject_INTERFACE_DEFINED)
 %ICreateObject_INTERFACE_DEFINED = 1
INTERFACE ICreateObject $IID_ICreateObject
 INHERIT IUnknown
 ' =====================================================================================
 METHOD CreateObject ( ' VTable offset = 12
 BYREF clsid AS GUID
 , BYVAL pUnkOuter AS IUnknown
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __ICreateObject_INTERFACE_DEFINED__ */
DECLARE FUNCTION PSFormatForDisplay LIB "propsys.dll" ALIAS "PSFormatForDisplay" ( BYREF propkey AS PROPERTYKEY , BYREF propvar AS ANY , BYVAL pdfFlags AS LONG , BYREF pwszText AS WSTRINGZ , BYVAL cchText AS QUAD ) AS LONG
DECLARE FUNCTION PSFormatForDisplayAlloc LIB "propsys.dll" ALIAS "PSFormatForDisplayAlloc" ( BYREF key AS PROPERTYKEY
 , BYREF propvar AS ANY
 , BYVAL pdff AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
DECLARE FUNCTION PSFormatPropertyValue LIB "propsys.dll" ALIAS "PSFormatPropertyValue" ( BYVAL pps AS IPropertyStore
 , BYVAL ppd AS IPropertyDescription
 , BYVAL pdff AS LONG
 , BYREF ppszDisplay AS DWORD
 ) AS LONG
'// Retrieve the image reference associated with a property value (if specified)
DECLARE FUNCTION PSGetImageReferenceForValue LIB "propsys.dll" ALIAS "PSGetImageReferenceForValue" ( BYREF propkey AS PROPERTYKEY , BYREF propvar AS PROPVARIANT , BYREF ppszImageRes AS QUAD ) AS LONG
%EQUATE `PKEY_PIDSTR_MAX = 10 ' // will take care of any long integer value
%EQUATE `GUIDSTRING_MAX = (1 + 8 + 1 + 4 + 1 + 4 + 1 + 4 + 1 + 12 + 1 + 1) ' // "{12345678-1234-1234-1234-123456789012}"
%EQUATE `PKEYSTR_MAX = (%GUIDSTRING_MAX + 1 + %PKEY_PIDSTR_MAX)
'// Convert a PROPERTYKEY to and from a PWSTR
DECLARE FUNCTION PSStringFromPropertyKey LIB "propsys.dll" ALIAS "PSStringFromPropertyKey" ( BYREF pkey AS PROPERTYKEY , BYREF psz AS WSTRINGZ , BYVAL cch AS QUAD ) AS LONG
DECLARE FUNCTION PSPropertyKeyFromString LIB "propsys.dll" ALIAS "PSPropertyKeyFromString" ( BYREF pszString AS WSTRINGZ
 , BYREF pkey AS PROPERTYKEY
 ) AS LONG
'// Creates an in-memory property store
'// Returns an IPropertyStore, IPersistSerializedPropStorage, and related interfaces interface
DECLARE FUNCTION PSCreateMemoryPropertyStore LIB "propsys.dll" ALIAS "PSCreateMemoryPropertyStore" ( BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Create a read-only, delay-bind multiplexing property store
'// Returns an IPropertyStore interface or related interfaces
DECLARE FUNCTION PSCreateDelayedMultiplexPropertyStore LIB "propsys.dll" ALIAS "PSCreateDelayedMultiplexPropertyStore" ( BYVAL flags AS LONG , BYVAL pdpsf AS IDelayedPropertyStoreFactory , BYREF rgStoreIds AS QUAD , BYVAL cStores AS QUAD , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Create a read-only property store from one or more sources (which each must support either IPropertyStore or IPropertySetStorage)
'// Returns an IPropertyStore interface or related interfaces
DECLARE FUNCTION PSCreateMultiplexPropertyStore LIB "propsys.dll" ALIAS "PSCreateMultiplexPropertyStore" ( BYVAL prgpunkStores AS IUnknown , BYVAL cStores AS QUAD , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Create a container for IPropertyChanges
'// Returns an IPropertyChangeArray interface
DECLARE FUNCTION PSCreatePropertyChangeArray LIB "propsys.dll" ALIAS "PSCreatePropertyChangeArray" ( BYREF rgpropkey AS PROPERTYKEY , BYREF rgflags AS LONG , BYREF rgpropvar AS ANY , BYVAL cChanges AS QUAD , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Create a simple property change
'// Returns an IPropertyChange interface
DECLARE FUNCTION PSCreateSimplePropertyChange LIB "propsys.dll" ALIAS "PSCreateSimplePropertyChange" ( BYVAL flags AS LONG , BYREF key AS PROPERTYKEY , BYREF propvar AS ANY , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Get a property description
'// Returns an IPropertyDescription interface
DECLARE FUNCTION PSGetPropertyDescription LIB "propsys.dll" ALIAS "PSGetPropertyDescription" ( BYREF propkey AS PROPERTYKEY , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
DECLARE FUNCTION PSGetPropertyDescriptionByName LIB "propsys.dll" ALIAS "PSGetPropertyDescriptionByName" ( BYREF pszCanonicalName AS WSTRINGZ
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
'// Lookup a per-machine registered file property handler
DECLARE FUNCTION PSLookupPropertyHandlerCLSID LIB "propsys.dll" ALIAS "PSLookupPropertyHandlerCLSID" ( BYREF pszFilePath AS WSTRINGZ , BYREF pclsid AS GUID ) AS LONG
'// Get a property handler, on Vista or downlevel to XP
'// punkItem is a shell item created with an SHCreateItemXXX API
'// Returns an IPropertyStore
DECLARE FUNCTION PSGetItemPropertyHandler LIB "propsys.dll" ALIAS "PSGetItemPropertyHandler" ( BYVAL punkItem AS IUnknown , BYVAL fReadWrite AS LONG , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Get a property handler, on Vista or downlevel to XP
'// punkItem is a shell item created with an SHCreateItemXXX API
'// punkCreateObject supports ICreateObject
'// Returns an IPropertyStore
DECLARE FUNCTION PSGetItemPropertyHandlerWithCreateObject LIB "propsys.dll" ALIAS "PSGetItemPropertyHandlerWithCreateObject" ( BYVAL punkItem AS IUnknown , BYVAL fReadWrite AS LONG , BYVAL punkCreateObject AS IUnknown , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Get or set a property value from a store
DECLARE FUNCTION PSGetPropertyValue LIB "propsys.dll" ALIAS "PSGetPropertyValue" ( BYVAL pps AS IPropertyStore , BYVAL ppd AS IPropertyDescription , BYREF ppropvar AS ANY ) AS LONG
DECLARE FUNCTION PSSetPropertyValue LIB "propsys.dll" ALIAS "PSSetPropertyValue" ( BYVAL pps AS IPropertyStore
 , BYVAL ppd AS IPropertyDescription
 , BYREF propvar AS ANY
 ) AS LONG
'// Interact with the set of property descriptions
DECLARE FUNCTION PSRegisterPropertySchema LIB "propsys.dll" ALIAS "PSRegisterPropertySchema" ( BYREF pszPath AS WSTRINGZ ) AS LONG
DECLARE FUNCTION PSUnregisterPropertySchema LIB "propsys.dll" ALIAS "PSUnregisterPropertySchema" ( BYREF pszPath AS WSTRINGZ
 ) AS LONG
DECLARE FUNCTION PSRefreshPropertySchema LIB "propsys.dll" ALIAS "PSRefreshPropertySchema" ( ) AS LONG
'// Returns either: IPropertyDescriptionList or IEnumUnknown interfaces
DECLARE FUNCTION PSEnumeratePropertyDescriptions LIB "propsys.dll" ALIAS "PSEnumeratePropertyDescriptions" ( BYVAL filterOn AS LONG , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Convert between a PROPERTYKEY and its canonical name
DECLARE FUNCTION PSGetPropertyKeyFromName LIB "propsys.dll" ALIAS "PSGetPropertyKeyFromName" ( BYREF pszName AS WSTRINGZ , BYREF ppropkey AS PROPERTYKEY ) AS LONG
DECLARE FUNCTION PSGetNameFromPropertyKey LIB "propsys.dll" ALIAS "PSGetNameFromPropertyKey" ( BYREF propkey AS PROPERTYKEY
 , BYREF ppszCanonicalName AS DWORD
 ) AS LONG
'// Coerce and canonicalize a property value
DECLARE FUNCTION PSCoerceToCanonicalValue LIB "propsys.dll" ALIAS "PSCoerceToCanonicalValue" ( BYREF key AS PROPERTYKEY , BYREF ppropvar AS ANY ) AS LONG
'// Convert a 'prop:' string into a list of property descriptions
'// Returns an IPropertyDescriptionList interface
DECLARE FUNCTION PSGetPropertyDescriptionListFromString LIB "propsys.dll" ALIAS "PSGetPropertyDescriptionListFromString" ( BYREF pszPropList AS WSTRINGZ , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Wrap an IPropertySetStorage interface in an IPropertyStore interface
'// Returns an IPropertyStore or related interface
DECLARE FUNCTION PSCreatePropertyStoreFromPropertySetStorage LIB "propsys.dll" ALIAS "PSCreatePropertyStoreFromPropertySetStorage" ( BYVAL ppss AS IPropertySetStorage , BYVAL grfMode AS QUAD , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// punkSource must support IPropertyStore or IPropertySetStorage
'// On success, the returned ppv is guaranteed to support IPropertyStore.
'// If punkSource already supports IPropertyStore, no wrapper is created.
DECLARE FUNCTION PSCreatePropertyStoreFromObject LIB "propsys.dll" ALIAS "PSCreatePropertyStoreFromObject" ( BYVAL punk AS IUnknown , BYVAL grfMode AS QUAD , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// punkSource must support IPropertyStore
'// riid may be IPropertyStore, IPropertySetStorage, IPropertyStoreCapabilities, or IObjectProvider
DECLARE FUNCTION PSCreateAdapterFromPropertyStore LIB "propsys.dll" ALIAS "PSCreateAdapterFromPropertyStore" ( BYVAL pps AS IPropertyStore , BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Talk to the property system using an interface
'// Returns an IPropertySystem interface
DECLARE FUNCTION PSGetPropertySystem LIB "propsys.dll" ALIAS "PSGetPropertySystem" ( BYREF riid AS GUID , BYREF ppv AS IUnknown ) AS LONG
'// Obtain a value from serialized property storage
DECLARE FUNCTION PSGetPropertyFromPropertyStorage LIB "propsys.dll" ALIAS "PSGetPropertyFromPropertyStorage" ( BYVAL psps AS BYTE PTR , BYVAL cb AS QUAD , BYREF rpkey AS PROPERTYKEY , BYREF ppropvar AS ANY ) AS LONG
'// Obtain a named value from serialized property storage
DECLARE FUNCTION PSGetNamedPropertyFromPropertyStorage LIB "propsys.dll" ALIAS "PSGetNamedPropertyFromPropertyStorage" ( BYVAL psps AS BYTE PTR , BYVAL cb AS QUAD , BYREF pszName AS WSTRINGZ , BYREF ppropvar AS ANY ) AS LONG
'// Helper functions for reading and writing values from IPropertyBag's.
DECLARE FUNCTION PSPropertyBag_ReadType LIB "propsys.dll" ALIAS "PSPropertyBag_ReadType" ( BYVAL propBag AS IPropertyBag , BYREF propName AS WSTRINGZ , BYREF var AS VARIANT , BYVAL type AS WORD ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadStr LIB "propsys.dll" ALIAS "PSPropertyBag_ReadStr" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS WSTRINGZ
 , BYVAL characterCount AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadStrAlloc LIB "propsys.dll" ALIAS "PSPropertyBag_ReadStrAlloc" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS DWORD
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadBSTR LIB "propsys.dll" ALIAS "PSPropertyBag_ReadBSTR" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS WSTRING
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteStr LIB "propsys.dll" ALIAS "PSPropertyBag_WriteStr" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS WSTRINGZ
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteBSTR LIB "propsys.dll" ALIAS "PSPropertyBag_WriteBSTR" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS WSTRING
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadInt LIB "propsys.dll" ALIAS "PSPropertyBag_ReadInt" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteInt LIB "propsys.dll" ALIAS "PSPropertyBag_WriteInt" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadSHORT LIB "propsys.dll" ALIAS "PSPropertyBag_ReadSHORT" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS INTEGER
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteSHORT LIB "propsys.dll" ALIAS "PSPropertyBag_WriteSHORT" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS INTEGER
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadLONG LIB "propsys.dll" ALIAS "PSPropertyBag_ReadLONG" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteLONG LIB "propsys.dll" ALIAS "PSPropertyBag_WriteLONG" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadDWORD LIB "propsys.dll" ALIAS "PSPropertyBag_ReadDWORD" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS DWORD
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteDWORD LIB "propsys.dll" ALIAS "PSPropertyBag_WriteDWORD" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS DWORD
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadBOOL LIB "propsys.dll" ALIAS "PSPropertyBag_ReadBOOL" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteBOOL LIB "propsys.dll" ALIAS "PSPropertyBag_WriteBOOL" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS LONG
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadPOINTL LIB "propsys.dll" ALIAS "PSPropertyBag_ReadPOINTL" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS POINTL
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WritePOINTL LIB "propsys.dll" ALIAS "PSPropertyBag_WritePOINTL" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS POINTL
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadPOINTS LIB "propsys.dll" ALIAS "PSPropertyBag_ReadPOINTS" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS POINTS
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WritePOINTS LIB "propsys.dll" ALIAS "PSPropertyBag_WritePOINTS" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS POINTS
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadRECTL LIB "propsys.dll" ALIAS "PSPropertyBag_ReadRECTL" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS RECTL
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteRECTL LIB "propsys.dll" ALIAS "PSPropertyBag_WriteRECTL" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS RECTL
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadStream LIB "propsys.dll" ALIAS "PSPropertyBag_ReadStream" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS IStream
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteStream LIB "propsys.dll" ALIAS "PSPropertyBag_WriteStream" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS IStream
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_Delete LIB "propsys.dll" ALIAS "PSPropertyBag_Delete" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadULONGLONG LIB "propsys.dll" ALIAS "PSPropertyBag_ReadULONGLONG" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS QUAD
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteULONGLONG LIB "propsys.dll" ALIAS "PSPropertyBag_WriteULONGLONG" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL value AS QUAD
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadUnknown LIB "propsys.dll" ALIAS "PSPropertyBag_ReadUnknown" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteUnknown LIB "propsys.dll" ALIAS "PSPropertyBag_WriteUnknown" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYVAL punk AS IUnknown
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadGUID LIB "propsys.dll" ALIAS "PSPropertyBag_ReadGUID" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS GUID
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WriteGUID LIB "propsys.dll" ALIAS "PSPropertyBag_WriteGUID" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS GUID
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_ReadPropertyKey LIB "propsys.dll" ALIAS "PSPropertyBag_ReadPropertyKey" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS PROPERTYKEY
 ) AS LONG
DECLARE FUNCTION PSPropertyBag_WritePropertyKey LIB "propsys.dll" ALIAS "PSPropertyBag_WritePropertyKey" ( BYVAL propBag AS IPropertyBag
 , BYREF propName AS WSTRINGZ
 , BYREF value AS PROPERTYKEY
 ) AS LONG
#ENDIF
