# SetObjectEnabled(Object, bool)

> Set the enabled state of the object.

## Definition

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

```csharp
public static void SetObjectEnabled(Object target, bool enabled)
```

### Parameters

**** (\[Object]\(/engine/6000.6/script-reference/unityengine/object)): **** (\[bool]\(https\://learn.microsoft.com/dotnet/api/system.boolean)):&#x20;
