IWICMetadataQueryReader::GetMetadataByName method

Retrieves the metadata block or item identified by a metadata query expression.

Syntax


HRESULT GetMetadataByName(
  [in]      LPCWSTR     wzName,
  [in, out] PROPVARIANT *pvarValue
);

Parameters

wzName [in]

Type: LPCWSTR

The query expression to the requested metadata block or item.

pvarValue [in, out]

Type: PROPVARIANT*

When this method returns, contains the metadata block or item requested.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

GetMetadataByName uses metadata query expressions to access embedded metadata. For more information on the metadata query language, see the Metadata Query Language Overview.

If multiple blocks or items exist that are expressed by the same query expression, the first metadata block or item found will be returned.

Requirements

Minimum supported client

Windows XP with SP2, Windows Vista [desktop apps | UWP apps]

Minimum supported server

Windows Server 2008 [desktop apps | UWP apps]

Header

Wincodec.h

IDL

Wincodec.idl

Library

Windowscodecs.lib

DLL

Windowscodecs.dll

See also

IWICMetadataQueryReader
Conceptual
WIC Metadata Overview
Metadata Query Language Overview
Overview of Reading and Writing Image Metadata
Other Resources
PROPVARIANT

 

 

Show: