> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XStoreQueryAddOnLicensesResultCount

> XStoreQueryAddOnLicensesResultCount

# XStoreQueryAddOnLicensesResultCount

Gets the number of licenses retrieved by [XStoreQueryAddonLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync).

## Syntax

```cpp theme={null}
HRESULT XStoreQueryAddOnLicensesResultCount(  
         XAsyncBlock* async,  
         uint32_t* count  
)  
```

### Parameters

*async*   \_In\_\
Type: [XAsyncBlock\*](/reference/system/xasync/structs/xasyncblock)

The XAsyncBlock passed to [XStoreQueryAddonLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync). The [XAsyncBlock](/reference/system/xasync/structs/xasyncblock) can be used to poll for the call's status and retrieve call results. See [XAsyncBlock](/reference/system/xasync/structs/xasyncblock) for more information.

*count*   \_Out\_\
Type: uint32\_t\*

On success contains the number of licenses retrieved.

### Return value

Type: HRESULT

HRESULT success or error code.

## Remarks

This result function allows you to retrieve the number of add-on licenses acquired when [XStoreQueryAddonLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync) was called. As such, this function should be called after [XStoreQueryAddonLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync) has been called, usually in the context of a callback function.

See [XStoreQueryAddonLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync) for a usage example.

## Requirements

**Header:** XStore.h (included in XGameRuntime.h)

**Library:** xgameruntime.lib

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

## See also

[XStore](/reference/system/xstore/xstore_members)\
[XStoreQueryAddonLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync)\
[XStoreQueryAddonLicensesResult](/reference/system/xstore/functions/xstorequeryaddonlicensesresult)


## Related topics

- [XStore](/reference/system/xstore/xstore_members.md)
- [Unity C# API wrappers for the GDK](/build/gdk-and-engines/unity/unity-api-wrappers.md)
- [XStoreQueryAddOnLicensesResult](/reference/system/xstore/functions/xstorequeryaddonlicensesresult.md)
- [XStoreQueryAddOnLicensesAsync](/reference/system/xstore/functions/xstorequeryaddonlicensesasync.md)
- [XStoreQueryPackageUpdatesResultCount](/reference/system/xstore/functions/xstorequerypackageupdatesresultcount.md)
