Cannot call method 'pullHandled' of undefined

2 posts, 0 answers
  1. Sasha
    Sasha avatar
    2 posts
    Member since:
    Jul 2010

    Posted 01 May 2012 Link to this post

    Testing in Chrome, using Twitter feed, I am trying to test the 'pullToRefresh' functionality but get this error in Chrome developer tools when I try to pull the list down. :

    1. Uncaught TypeError: Cannot call method 'pullHandled' of undefined
      1. g.extend.refreshkendo.mobile.min.js:2346
      2. e.extend.proxy.gjquery.min.js:538
      3. y.extend.triggerkendo.mobile.min.js:136
      4. o.extend._processkendo.mobile.min.js:1681
      5. o.extend.successkendo.mobile.min.js:1664
      6. e.extend.proxy.gjquery.min.js:538
      7. p.extend.read.c.successkendo.mobile.min.js:1503
      8. f.Callbacks.njquery.min.js:590
      9. f.Callbacks.o.fireWithjquery.min.js:635
      10. f.ajaxTransport.send.d.onload.d.onreadystatechange

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <head>
        <title>My Open Cal</title>
     
        <!-- Kendo UI Files -->
        <link href="styles/kendo.mobile.all.min.css" rel="stylesheet" type="text/css" />
        <script src="js/jquery.min.js" type="text/javascript"></script>
        <script src="js/kendo.mobile.min.js" type="text/javascript"></script>
        <script>
            $( //jQuery page load
                function ()
                {
                    var app = new kendo.mobile.Application($(document.body), { layout: "layout", icon: "/images/xboxavatar.png" });
                    $("#ulMyCal").kendoMobileListView({
                        appendOnRefresh: true,
                        pullToRefresh: true,
                        pullTemplate: "Pull to refresh",
                        refreshTemplate: "Loading...",
                        dataSource: new kendo.data.DataSource(
                        {
     
                                    transport:
                                    {
                                        read:
                                        {
                                            url: "http://search.twitter.com/search.json",
                                            contentType: "application/json; charset=utf-8",
                                            type: "GET",
                                            dataType: "jsonp",
                                            data:
                                            {
                                                q: "#tampa"
                                            }
                                        }
                                    },
     
                                    schema: {
                                        data: "results"
                                         
                                    }
                        }),
                        template:"<p>${text}</p>"
     
                });
     
            })
        </script>
    </head>
    <body>
     
        <!-- Layout for all views in the application, as specified when the app is created -->
        <div data-role="layout" data-id="layout">
          <div data-role="header" >
              <div data-role="navbar">
                <span data-role="view-title">My Test</span>
              </div>
          </div>
          <div data-role="footer">
              <div data-role="tabstrip">
                <a href="#index" data-icon="organize">My Calendar</a>
                <a href="#search" data-icon="search">Search</a>
                <a href="settings.htm" data-icon="settings">Settings</a>
              </div>
         </div>
        </div>
     
     
        <div data-role="view" id="index" data-title = "My Calendar">
            <div style="text-align:center">
                <ul id="ulMyCal" data-style="inset">
                 
                </ul>
            </div>
        </div>
     
        <div data-role="view" id = "search" data-title = "Search">
             
        </div>
     
    </body>
    </html>
  2. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 02 May 2012 Link to this post

    Hi,

    The widgets should be initialized at the view init event handler. In your case however, there is an additional limitation in the official release (which is resolved in the latest internal builds) - the pull to refresh functionality can only be used with declarative widget initialization. 

    Kind regards,
    Petyo
    the Telerik team
    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