QueryActCtxSettingsW function (winbase.h)

The QueryActCtxSettingsW function specifies the activation context, and the namespace and name of the attribute that is to be queried.

Syntax

BOOL QueryActCtxSettingsW(
  [in, optional]  DWORD  dwFlags,
  [in, optional]  HANDLE hActCtx,
  [in, optional]  PCWSTR settingsNameSpace,
  [in]            PCWSTR settingName,
  [out]           PWSTR  pvBuffer,
  [in]            SIZE_T dwBuffer,
  [out, optional] SIZE_T *pdwWrittenOrRequired
);

Parameters

[in, optional] dwFlags

This value must be 0.

[in, optional] hActCtx

A handle to the activation context that is being queried.

[in, optional] settingsNameSpace

A pointer to a string that contains the value "http://schemas.microsoft.com/SMI/2005/WindowsSettings" or NULL. These values are equivalent.

Windows 8 and Windows Server 2012:  A pointer to a string that contains the value "http://schemas.microsoft.com/SMI/2011/WindowsSettings" is also a valid parameter. A NULL is still equivalent to the previous value.

[in] settingName

The name of the attribute to be queried.

[out] pvBuffer

A pointer to the buffer that receives the query result.

[in] dwBuffer

The size of the buffer in characters that receives the query result.

[out, optional] pdwWrittenOrRequired

A pointer to a value which is the number of characters written to the buffer specified by pvBuffer or that is required to hold the query result.

Return value

If the function succeeds, it returns TRUE. Otherwise, it returns FALSE.

This function sets errors that can be retrieved by calling GetLastError. For an example, see Retrieving the Last-Error Code. For a complete list of error codes, see System Error Codes.

Requirements

   
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2008 [desktop apps only]
Target Platform Windows
Header winbase.h (include Windows.h)
Library Kernel32.lib
DLL Kernel32.dll