# deviceDisconnected

> Defines the delegate to use to register events when an InputDevice is disconnected.

## Definition

* **Type:** Event
* **Namespace:** [UnityEngine.XR](/engine/6000.0/script-reference/unityengine/xr.md)
* **Assembly:** UnityEngine.XRModule

```csharp
public static event Action<InputDevice> deviceDisconnected
```

### Remarks

This delegate allows you to receive device disconnection events, so you know when the list of devices changes.

**Note**: [IsValid](/engine/6000.0/script-reference/unityengine/xr/inputdevice/isvalid.md) will be false for the passed-in device, and the only device data available will be [InputDevice.name](/engine/6000.0/script-reference/unityengine/xr/inputdevice/name.md), [InputDevice.role](/engine/6000.0/script-reference/unityengine/xr/inputdevice/role.md), and comparison against other InputDevice objects.
