Summary
Tries to the specified resource by searching up the logical tree and then global styles.
- Namespace
- Avalonia
.Controls - Containing Type
- Resource
Node Extensions
Syntax
public static bool TryFindResource(this IResourceHost control, object key, out object? value)
Parameters
Name | Type | Description |
---|---|---|
control | IResourceHost | The control. |
key | object | The resource key. |
value | object? | On return, contains the resource if found, otherwise null. |
Return Value
Type | Description |
---|---|
bool | True if the resource was found; otherwise false. |