Class DependencyObjectExtensions
Represents an extension to find parent or child of an element.
Inheritance
System.Object
DependencyObjectExtensions
Namespace: Syncfusion.UI.Xaml.PivotChart
Assembly: Syncfusion.SfPivotChart.UWP.dll
Syntax
public static class DependencyObjectExtensions : Object
Methods
FindElementOfType<T>(FrameworkElement)
Searches the sub tree of an element (including that element) for an element of a particular type.
Declaration
public static T FindElementOfType<T>(this FrameworkElement element)
where T : FrameworkElement
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.FrameworkElement | element | The element used to search. |
Returns
Type | Description |
---|---|
T | The searched element. |
Type Parameters
Name | Description |
---|---|
T | The type of searched element. |
FindElementOfTypeWithName<T>(FrameworkElement, String)
Searches the sub tree of an element (including that element) for an element with specific name and particular type.
Declaration
public static T FindElementOfTypeWithName<T>(this FrameworkElement element, string name)
where T : FrameworkElement
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.FrameworkElement | element | The element used to search. |
System.String | name | The name of element searched for. |
Returns
Type | Description |
---|---|
T | The searched element. |
Type Parameters
Name | Description |
---|---|
T | The type of searched element. |
FindParentElementOfType<T>(FrameworkElement)
Gets the parent element of the specified framework element in the visual tree.
Declaration
public static T FindParentElementOfType<T>(this FrameworkElement element)
where T : class
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.FrameworkElement | element | The child element. |
Returns
Type | Description |
---|---|
T | The parent element. |
Type Parameters
Name | Description |
---|---|
T | The type of parent element. |