Note
Access to this page requires authorization. You can try signing in or .
Access to this page requires authorization. You can try .
UIElement.Focus(FocusState) Method
Definition
- Namespace:
- Microsoft.UI.Xaml
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Attempts to set focus to this element.
public:
virtual bool Focus(FocusState value) = Focus;
bool Focus(FocusState const& value);
public bool Focus(FocusState value);
function focus(value)
Public Function Focus (value As FocusState) As Boolean
Parameters
- value
- FocusState
How this element obtains focus.
Returns
Boolean
bool
True if keyboard focus and logical focus were set to this element. False if only logical focus was set to this element, or if the call to this method did not force the focus to change.
Applies to
Feedback
Was this page helpful?
