IWICMetadataQueryReader::GetLocation method (wincodec.h)

Retrieves the current path relative to the root metadata block.

Syntax

HRESULT GetLocation(
  [in]      UINT  cchMaxLength,
  [in, out] WCHAR *wzNamespace,
  [out]     UINT  *pcchActualLength
);

Parameters

[in] cchMaxLength

Type: UINT

The length of the wzNamespace buffer.

[in, out] wzNamespace

Type: WCHAR*

Pointer that receives the current namespace location.

[out] pcchActualLength

Type: UINT*

The actual buffer length that was needed to retrieve the current namespace location.

Return value

Type: HRESULT

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

Remarks

If you pass NULL to wzNamespace, GetLocation ignores cchMaxLength and returns the required buffer length to store the path in the variable that pcchActualLength points to.

If the query reader is relative to the top of the metadata hierarchy, it will return a single-char string.

If the query reader is relative to a nested metadata block, this method will return the path to the current query reader.

Requirements

Requirement Value
Minimum supported client Windows XP with SP2, Windows Vista [desktop apps | UWP apps]
Minimum supported server Windows Server 2008 [desktop apps | UWP apps]
Target Platform Windows
Header wincodec.h
Library Windowscodecs.lib
DLL Windowscodecs.dll

See also

Conceptual

IWICMetadataQueryReader

Overview of Reading and Writing Image Metadata

WIC Metadata Overview