Dialog-close-notification

4 posts, 1 answers
  1. Anna
    Anna avatar
    59 posts
    Member since:
    Jul 2015

    Posted 19 Jul Link to this post

    Hi team,

    I'm wondering if there is a way to pop-up a notification dialog on Kendo Window closing to warn user about unsaved changes, and allow them to choose between continue closing anyway and undo the closing command so they can save their change? Just like the Page Close Notification dialog?

     

    Best,

     

    Anna

  2. Answer
    Ivan Danchev
    Admin
    Ivan Danchev avatar
    1326 posts

    Posted 21 Jul Link to this post

    Hi Anna,

    Here's a dojo example, which shows how you can use the widget's API to display a Dialog that asks the user to confirm closing the Window. Closing the Window is initially prevented in the Dialog's show event handler. If the user then confirms the Window is closed by calling its close method in the Dialog's Yes action handler.

    Regards,
    Ivan Danchev
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  3. Anna
    Anna avatar
    59 posts
    Member since:
    Jul 2015

    Posted 21 Jul Link to this post

    Hi Ivan,

    Thank you for getting back to me. I'm using AngularJs version of Kendo UI. Can you explain a bit why select "Cancel" of the Kendo dialog will stop the main Window from closing? 

    I mean look at the dojo you give above, the solution seems to be invoke a Kendo Dialog on close event. If I don't use Kendo Dialog, can I substitute it with other mechanism? 

     

    Thanks,

     

    Anna

  4. Anna
    Anna avatar
    59 posts
    Member since:
    Jul 2015

    Posted 21 Jul in reply to Anna Link to this post

    Nevermind. I see now. It's the e.preventDefault() that did the magic.
Back to Top