Edit this page


Centers the window within the viewport.

If the Window has no set dimensions and is centered before its content is loaded with Ajax, it is probably going to resize after the content is loaded. This naturally changes the position of the widget on the screen and it is no longer centered. If this is a requirement, then either center the Window in its refresh event, or set some explicit dimensions.


kendo.ui.Window Returns the window object to support chaining, for example center and open the Window with a single expression.


<div id="dialog"></div>
var dialog = $("#dialog").data("kendoWindow");
// chaining example
// dialog.center().open();
Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article