ResourceProviderExtensions.

TryFindResource(IResourceNode, string, object) Method

Summary

Tries to the specified resource by searching up the logical tree and then global styles.
Namespace
Avalonia.Controls
Containing Type
ResourceProviderExtensions

Syntax

public static bool TryFindResource(this IResourceNode control, string key, out object value)

Parameters

Name Type Description
control IResourceNode The control.
key string 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.