Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

Disable bounce scrolling in a tableview

Hi,

I would like to know how to disable bounce scrolling in a tableview for the IOS platform.

Haven't found anything about it.

Thanks in advance.

— asked November 7th 2011 by Daniel Soto
  • bounce
  • ios
  • tableview
0 Comments

4 Answers

  • Without building an own Titanium module, I was successful with following workaround.

    Transform your code

    var tableView = Ti.UI.createTableView({
        top: myTop,
        height: myHeight,
        // ...
    });
    
    myWin.add(tableView);
    

    into:

    // workaround
    var containerScrollView = Ti.UI.createScrollView({
        top: myTop,
        height: myHeight,
        // ...
        disableBounce: true
    });
    
    var tableView = Ti.UI.createTableView({
        top: 0,
        height: 'auto',
        // ...
        scrollable: false
    });
    
    containerScrollView.add(tableView);
    myWin.add(containerScrollView);
    

    It disables table view's scrolling.
    The scrolling functionality is undertaken by a container scroll view (with disabled bouncing).

    — answered July 23rd 2015 by Hendrik Bugdoll
    permalink
    1 Comment
    • The scrolling does not work on Android…

      — commented July 27th 2015 by Hendrik Bugdoll
  • Try disableBounce but I'm not sure if is not a scrollview only property.

    — answered November 7th 2011 by Dan Tamas
    permalink
    1 Comment
  • Already tried that one, doesn't work

    — answered November 7th 2011 by Daniel Soto
    permalink
    0 Comments
  • have you found any solution for that?

    — answered April 3rd 2013 by Ario Barzan
    permalink
    1 Comment
    • I know IOS6 added disablebounce, but I don't think Ti 3 has it.

      — commented April 7th 2013 by Bryce Wilkinson
The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.