# ToInstanceID(ObjectIdentifier)

> Tries to return the InstanceID that represents this ObjectIdentifier.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.Build.Content](/engine/6000.5/script-reference/unityeditor/build/content.md)
* **Assembly:** UnityEditor.CoreModule

> **Warning:**
>
> **Removed.** Deprecated, use ToEntityId instead.

```csharp
public static int ToInstanceID(ObjectIdentifier objectId)
```

### Parameters

**** (\[ObjectIdentifier]\(/engine/6000.5/script-reference/unityeditor/build/content/objectidentifier)):&#x20;

### Returns

| Type                                                       | Description |
| ---------------------------------------------------------- | ----------- |
| [int](https://learn.microsoft.com/dotnet/api/system.int32) |             |

### Remarks

Returns 0 if the ObjectIdentifier is invalid.
