New to Kendo UI for AngularStart a free 30-day trial

WindowService

A service for opening Windows dynamically (see example).

Constructors

WindowService

(containerService: WindowContainerService)

Parameters

containerService

WindowContainerService

Methods

open

Opens a Window component.

ts
@Component({
  selector: 'my-app',
  template: `
    <button kendoButton (click)="open()">Open window</button>
    <div kendoWindowContainer></div>
  `
})
export class AppComponent {
    constructor( private windowService: WindowService ) {}

    public open() {
        var window = this.windowService.open({
          title: "My window",
          content: "My content!"
        });

        window.result.subscribe((result) => {
          if (result instanceof WindowCloseResult) {
            console.log("Window was closed");
          }
        });
    }
}
Parameters

settings

WindowSettings

The settings that define the Window.

Returns

WindowRef

  • A reference to the Window object.
In this article
ConstructorsWindowServiceMethods
Not finding the help you need?
Contact Support