GetCurrentActCtx function (winbase.h)

The GetCurrentActCtx function returns the handle to the active activation context of the calling thread.

Syntax

BOOL GetCurrentActCtx(
  [out] HANDLE *lphActCtx
);

Parameters

[out] lphActCtx

Pointer to the returned ACTCTX structure that contains information on the active activation context.

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.

Remarks

The calling thread is responsible for releasing the handle of the returned activation context. This function can return a null handle if no activation contexts have been activated by this thread. This is not an error.

Requirements

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

See also

ACTCTX