# IsSelected(VisualElement)

> Check if element is selected.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.Experimental.GraphView](/engine/6000.6/script-reference/unityeditor/experimental/graphview.md)
* **Assembly:** UnityEditor

```csharp
bool IsSelected(VisualElement selectionContainer)
```

### Parameters

**** (\[VisualElement]\(/engine/6000.6/script-reference/unityengine/uielements/visualelement)): Container in which the selection is tracked.

### Returns

| Type                                                          | Description                        |
| ------------------------------------------------------------- | ---------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if selected. False otherwise. |
