# Sandbox.UI.Panel.GetChildIndex

```csharp
int GetChildIndex(Panel panel)
```

Returns the index at which the given panel is [parented](/api/Sandbox.UI.Panel/Parent) to this panel, or -1 if it is not.

### Parameters

- `panel` (`Panel`)

### Returns

`int`

Declared in [Sandbox.UI.Panel](/api/Sandbox.UI.Panel).
Assembly: `Sandbox.Engine`.
