Export (0) Print
Expand All
Expand Minimize

MsiSummaryInfoGetProperty function

The MsiSummaryInfoGetProperty function gets a single property from the summary information stream.

Note  The meaning of the property value depends on whether the summary information stream is for an installation database (.msi file), transform (.mst file) or patch (.msp file). See Summary Property Descriptions and Summary Information Stream Property Set for more information about summary information properties.

Syntax


UINT MsiSummaryInfoGetProperty(
  _In_     MSIHANDLE hSummaryInfo,
  _In_     UINT uiProperty,
  _Out_    UINT *puiDataType,
  _Out_    INT *piValue,
  _Out_    FILETIME *pftValue,
  _Out_    LPTSTR szValueBuf,
  _Inout_  DWORD *pcchValueBuf
);

Parameters

hSummaryInfo [in]

Handle to summary information.

uiProperty [in]

Specifies the property ID of the summary property. This parameter can be a property ID listed in the Summary Information Stream Property Set. This function does not return values for PID_DICTIONARY OR PID_THUMBNAIL property.

puiDataType [out]

Receives the returned property type. This parameter can be a type listed in the Summary Information Stream Property Set.

piValue [out]

Receives the returned integer property data.

pftValue [out]

Pointer to a file value.

szValueBuf [out]

Pointer to the buffer that receives the null terminated summary information property value. Do not attempt to determine the size of the buffer by passing in a null (value=0) for szValueBuf. You can get the size of the buffer by passing in an empty string (for example ""). The function then returns ERROR_MORE_DATA and pcchValueBuf contains the required buffer size in TCHARs, not including the terminating null character. On return of ERROR_SUCCESS, pcchValueBuf contains the number of TCHARs written to the buffer, not including the terminating null character. This parameter is an empty string if there are no errors.

pcchValueBuf [in, out]

Pointer to the variable that specifies the size, in TCHARs, of the buffer pointed to by the variable szValueBuf. When the function returns ERROR_SUCCESS, this variable contains the size of the data copied to szValueBuf, not including the terminating null character. If szValueBuf is not large enough, the function returns ERROR_MORE_DATA and stores the required size, not including the terminating null character, in the variable pointed to by pcchValueBuf.

Return value

The MsiSummaryInfoGetProperty function returns one of the following values:

ERROR_INVALID_HANDLE

An invalid or inactive handle was supplied.

ERROR_INVALID_PARAMETER

An invalid parameter was passed to the function.

ERROR_MORE_DATA

The buffer passed in was too small to hold the entire value.

ERROR_SUCCESS

The function succeeded.

ERROR_UNKNOWN_PROPERTY

The property is unknown.

Remarks

If ERROR_MORE_DATA is returned, the parameter which is a pointer gives the size of the buffer required to hold the string. If ERROR_SUCCESS is returned, it gives the number of characters written to the string buffer. Therefore you can get the size of the buffer by passing in an empty string (for example "") for the parameter that specifies the buffer. Do not attempt to determine the size of the buffer by passing in a Null (value=0).

Windows Installer functions that return data in a user provided memory location should not be called with null as the value for the pointer. These functions return a string or return data as integer pointers, but return inconsistent values when passing null as the value for the output argument. For more information, see Passing Null as the Argument of Windows Installer Functions.

The property information returned by the MsiSummaryInfoGetProperty function is received by the piValue, pftValue, or szValueBuf parameter depending upon the type of property value that has been specified in the puiDataType parameter.

Requirements

Version

Windows Installer 5.0 on Windows Server 2012, Windows 8, Windows Server 2008 R2 or Windows 7. Windows Installer 4.0 or Windows Installer 4.5 on Windows Server 2008 or Windows Vista. Windows Installer on Windows Server 2003 or Windows XP

Header

Msiquery.h

Library

Msi.lib

DLL

Msi.dll

Unicode and ANSI names

MsiSummaryInfoGetPropertyW (Unicode) and MsiSummaryInfoGetPropertyA (ANSI)

See also

Passing Null as the Argument of Windows Installer Functions
Summary Information Property Functions
Summary Information Stream Property Set
Summaryinfo.Property

 

 

Community Additions

ADD
Show:
© 2014 Microsoft