Titanium Community Questions & Answer Archive

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

Trying to reload/refresh page with a button

Hi,

I'm trying to reload a page with a button. I can't seem to get the button to do anything. The current window just needs to be reloaded. Similar to hitting refresh on the browser.

Thanks in advance.

<script src='http://pastie.org/1041928.js'></script>

— asked July 13th 2010 by Dave Devitt
  • button
  • iphone
  • refresh
  • reload
0 Comments

3 Answers

  • Accepted Answer

    Depends how is your window built, what it's made of. For table view, do as Richie said, check the table_view_refresh.js. Hints :

    Clear table view data :

    tableview.setData([]);
    

    Set new data :

    tableview.setData(newDataArray);
    
    — answered July 14th 2010 by Jean-Philippe Boily
    permalink
    0 Comments
  • Hi

    I havnt actually got to refresh in my app yet. So I can't give you an example I have tried

    But… Have you looked at the kitchen sink example/table_view_refresh.js

    Which may give you an idea on how to do it

    — answered July 13th 2010 by Richie Mortimer
    permalink
    0 Comments
  • I will take a look thanks. Anyone else doing this too?

    — answered July 13th 2010 by Dave Devitt
    permalink
    0 Comments
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.