# GetMaterialPropertyNames(Object[])

> Gets the shader property names of the materials you pass in.

## Definition

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

```csharp
public static string[] GetMaterialPropertyNames(Object[] mats)
```

### Parameters

**** (\[Object\[]]\(/engine/6000.3/script-reference/unityengine/object)): The selected materials.

### Returns

| Type                                                               | Description                          |
| ------------------------------------------------------------------ | ------------------------------------ |
| [string\[\]](https://learn.microsoft.com/dotnet/api/system.string) | Returns the material property names. |

### Remarks

When implementing custom MaterialEditors, you'd usually pass the `this.targets` array to this function, where `this.targets` is all the selected materials.

Additional Resources: [MaterialProperty](/engine/6000.3/script-reference/unityeditor/materialproperty.md).
