# TryGetProperty(ref TContainer, string, out IProperty<TContainer>)

> Gets the property associated with the specified name.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Properties](/engine/6000.0/script-reference/unity/properties.md)
* **Assembly:** UnityEngine.PropertiesModule

## TryGetProperty(T, string, IProperty\<T>)

```csharp
bool TryGetProperty(ref TContainer container, string name, out IProperty<TContainer> property)
```

### Parameters

**** (T): The container hosting the data.**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): The name of the property to get.**** (\[IProperty\<T>]\(/engine/6000.0/script-reference/unity/properties/iproperty)): When this method returns, contains the property associated with the specified name, if the name is found; otherwise, null.

### Returns

| Type                                                          | Description                                                                                                                                                                           |
| ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | `true` if the [INamedProperties\<TContainer>](/engine/6000.0/script-reference/unity/properties/inamedproperties1.md) contains a property with the specified name; otherwise, `false`. |
