ControlExtensionsGetControlT Method
Finds the named control in the scope of the specified control and throws if not found.
Namespace: Avalonia.ControlsAssembly: Avalonia.Controls (in Avalonia.Controls.dll) Version: 11.3.999
public static T GetControl<T>(
this Control control,
string name
)
where T : Control
<ExtensionAttribute>
Public Shared Function GetControl(Of T As Control) (
control As Control,
name As String
) As T
[<ExtensionAttribute>]
static member GetControl :
control : Control *
name : string -> 'T when 'T : Control
- control Control
- The control to look in.
- name String
- The name of the control to find.
- T
- The type of the control to find.
TThe control.In Visual Basic and C#, you can call this method as an instance method on any object of type
Control. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).