# GetLayerValueFromName(string)

> Returns the final sorting layer value. Additional Resources: SortingLayer.GetLayerValueFromID.

## Definition

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

```csharp
public static int GetLayerValueFromName(string name)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): The unique value of the sorting layer as returned by any renderer's sortingLayerID property.

### Returns

| Type                                                       | Description                                                    |
| ---------------------------------------------------------- | -------------------------------------------------------------- |
| [int](https://learn.microsoft.com/dotnet/api/system.int32) | The final sorting value of the layer relative to other layers. |
