# TrySetRenderingLayerName(int, string)

> Give a possibility to change a Rendering Layer name.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.Rendering](/engine/6000.0/script-reference/unityeditor/rendering.md)
* **Assembly:** UnityEditor

```csharp
public static bool TrySetRenderingLayerName(int index, string name)
```

### Parameters

**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): The index of the rendering layer to change.**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): New name for the Rendering Layer.

### Returns

| Type                                                          | Description                                  |
| ------------------------------------------------------------- | -------------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | Returns `true` if the change was successful. |
