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

# XblSocialManagerGetLocalUserCount

> XblSocialManagerGetLocalUserCount

# XblSocialManagerGetLocalUserCount

获取 SocialManager 当前跟踪的本地用户数量。

## 语法

```cpp theme={null}
size_t XblSocialManagerGetLocalUserCount(  
)  
```

### 参数

### 返回值

类型：size\_t

SocialManager 当前跟踪的本地用户数量。

## 备注

若要添加要跟踪的本地用户，请调用 [XblSocialManagerAddLocalUser](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanageraddlocaluser.md)。若要从跟踪中移除本地用户，请调用 [XblSocialManagerRemoveLocalUser](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanagerremovelocaluser.md)。必须先调用此函数，然后再调用 [XblSocialManagerGetLocalUsers](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanagergetlocalusers.md)。

## 要求

**标头：** social\_manager\_c.h

**库：** Microsoft.Xbox.Services.14x.GDK.C.lib

## 另请参阅

[social\_manager\_c](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/social_manager_c_members.md)


## Related topics

- [XblSocialManagerGetLocalUsers](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanagergetlocalusers.md)
- [social_manager_c](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/social_manager_c_members.md)
- [XblSocialManagerUserGroupGetLocalUser](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanagerusergroupgetlocaluser.md)
- [XblSocialManagerUserGroupGetUsers](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanagerusergroupgetusers.md)
- [XblSocialManagerAddLocalUser](https://docs.xbox.com/zh-CN/reference/live/xsapi-c/social_manager_c/functions/xblsocialmanageraddlocaluser.md)
