# ToggleSelection()

> Toggles the selection state of the current selection.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Hierarchy](/engine/6000.5/script-reference/unity/hierarchy.md)
* **Assembly:** UnityEngine.HierarchyModule

```csharp
public void ToggleSelection()
```
