FocusHelper.SetFocusTarget(UIElement, UIElement) Method

Definition

Sets the focus target for an element. The focus target is automatically focused whenever the DependencyObject the target is attached to receives direct keyboard focus.

public:
 static void SetFocusTarget(System::Windows::UIElement ^ element, System::Windows::UIElement ^ value);
public static void SetFocusTarget (System.Windows.UIElement element, System.Windows.UIElement value);
static member SetFocusTarget : System.Windows.UIElement * System.Windows.UIElement -> unit
Public Shared Sub SetFocusTarget (element As UIElement, value As UIElement)

Parameters

element
UIElement

The element which should have a focus target attached to it.

value
UIElement

The new focus target for the element.

Applies to