app.navigate() in data-before-show

2 posts, 0 answers
  1. Robby Parker
    Robby Parker avatar
    18 posts
    Member since:
    Jul 2012

    Posted 15 Jul 2015 Link to this post

    I can't seem to get app.navigate to switch to a local view. No errors in console.

    Please tell me why this simple example doesn't work.


    <div data-role="view" data-layout="default" id="journalDefault" data-before-show="doesNeedLogin">
        Journal Entries
    <div data-role="view" data-layout="default" id="journalAddNew">
        Add Entry. Get ID from Listview.
    <div data-role="view" data-layout="default" id="journalLogin">
        Need to login.


    function doesNeedLogin(e)
        var isLoggedIn = false;
        if (isLoggedIn)
            alert("Logged In");
            alert("Not logged in");
            //show them login view

  2. Petyo
    Petyo avatar
    2439 posts

    Posted 17 Jul 2015 Link to this post


    you need to call prevent default - please check the snippet in the documentation.
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
Back to Top