> ## 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.

# PartyChatControl::GetDevice

> Returns the device this chat control is associated with.

Returns the device this chat control is associated with.

## Syntax

```cpp theme={null}
PartyError GetDevice(  
    PartyDevice** device  
)  
```

### Parameters

**`device`**   [PartyDevice\*\*](/services/playfab/multiplayer/networking/reference/classes/PartyDevice/partydevice)\
*library-allocated output*

The output device this chat control is associated with.

### Return value

PartyError

`c_partyErrorSuccess` if the call succeeded or an error code otherwise. The human-readable form of the error code can be retrieved via [PartyManager::GetErrorMessage()](/services/playfab/multiplayer/networking/reference/classes/PartyManager/methods/partymanager_geterrormessage).

## Requirements

**Header:** Party.h

## See also

[PartyChatControl](/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/partychatcontrol)


## Related topics

- [PartyChatControl](/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/partychatcontrol.md)
- [PartyChatControl::SetCustomContext](/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/methods/partychatcontrol_setcustomcontext.md)
- [PartyChatControl::GetNetworks](/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/methods/partychatcontrol_getnetworks.md)
- [PartyChatControl::GetLocal](/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/methods/partychatcontrol_getlocal.md)
- [PartyChatControl::GetEntityId](/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/methods/partychatcontrol_getentityid.md)
