New to Kendo UI for Angular? Start a free 30-day trial
Initial Focus
Updated on Oct 27, 2026
The Kendo UI for Angular Window can move focus to its wrapper or to an element inside it when it opens.
By default, the Window focuses its wrapper. To focus an element inside the Window instead, set the autoFocusedElement property to a CSS selector that matches that element.
The following example focuses the input inside the first kendo-textbox when the Window opens.
Loading ...
Setting Initial Focus with Services
When you open a Window through the WindowService to create Window instances dynamically based on user interaction, set autoFocusedElement in the WindowSettings object.
ts
constructor(private windowService: WindowService) {}
public openWindowForm(): void {
const windowRef = this.windowService.open({
content: UserInfoComponent,
autoFocusedElement: '#name',
// You can add other WindowSettings options, such as title or htmlAttributes.
});
}
The following example focuses an input in the content when the service opens the Window.
Loading ...