Skip to main content
Gets a list of achievements in a specific progress state for a player.

Syntax

Parameters

xboxUserId   _In_
Type: uint64_t
The XBOX User ID of the player. sortField   _In_
Type: XblAchievementOrderBy
The field to sort the list of achievements on. TitleId will behave the same as DefaultOrder, as AchievementsManager only handles one title at a time. sortOrder   _In_
Type: XblAchievementsManagerSortOrder
The direction by which to sort the list of achievements. achievementState   _In_
Type: XblAchievementProgressState
The achievement state to include in the results. achievementsResult   _Outptr_result_maybenull_
Type: XblAchievementsManagerResultHandle*
The handle to the result of AchievementsManager API calls. This handle is used by other APIs to get the achievement objects matching the API that was called. The handle must be closed using XblAchievementsManagerResultCloseHandle when the result is no longer needed.

Return value

Type: HRESULT Returns S_OK on success. Possible error codes include the following. This list isn’t exhaustive.

Remarks

Sorting is supported only on unlock time. When sortField is XblAchievementOrderBy::UnlockTime, set sortOrder to XblAchievementsManagerSortOrder::Ascending or XblAchievementsManagerSortOrder::Descending. For any other sortField, set sortOrder to XblAchievementsManagerSortOrder::Unsorted. Other combinations return E_INVALIDARG.

Requirements

Header: achievements_manager_c.h Library: Microsoft.Xbox.Services.142.C.lib or Microsoft.Xbox.Services.143.C.lib

See also

achievements_manager_c
Last modified on October 29, 2026