New to Kendo UI for jQuery? Download free 30-day trial

Predefined Types

The Dialog provides options for rendering predefined dialogs by setting its kendo object.

For more information, refer the API documentation of:

The following example demonstrates how to call the alert, confirm, and prompt Dialogs.

kendo.alert("String to alert");
kendo.confirm("Continue?");
kendo.prompt("enter value", "123"); // 123 is the default value.

To interrupt the current thread for the confirm and prompt Dialogs in a similar way the browser does, use promises.

kendo.confirm("Continue?")
    .done(function() { console.log("Ok") })
    .fail(function() { console.log("Cancel") });
kendo.prompt("enter value")
    .done(function(value) { console.log(value); })
    .fail(function() { console.log("Cancel") });

See Also

In this article