FrameworkElementParentT Method

Progress Software Corporation - Testing Framework 2018.1 Automation Infrastructure
Get the parent control of this control that is of type T.

Namespace:  ArtOfTest.WebAii.Silverlight
Assembly:  ArtOfTest.WebAii (in ArtOfTest.WebAii.dll) Version: 2018.1.116.0 (2018.1.116.0)
Syntax

public T Parent<T>()
where T : IFrameworkElement

Type Parameters

T
The desired control type to match (i.e. 'Button', 'Calendar' ...etc)

Return Value

Type: T
The parent control of specified type.

Implements

IFrameworkElementParentT
Remarks

This function will traverse up the VisualTree until it finds the desired type. This function will also match custom control type that inherit from type T. For explicit matchings use Parent(string)
See Also

Reference