0

I have implemented pull to refresh using an library from https://github.com/chrisbanes/Android-PullToRefresh but when i call the demo function(mylistview.demo()) on my listview object from my fragment,the function doesn't execute.

The demo function works when i call it from an onclicklistener so I think the problem has to do with the function being executed before the fragment is loaded. How can I solve this problem?

Michael Celey
  • 12,645
  • 6
  • 57
  • 62
littleibex
  • 1,705
  • 2
  • 14
  • 35

1 Answers1

0

If you are making the call in OnCreate(), that is probably too early. Try calling it in OnStart() instead.

I can only assume where you are calling it since you haven't specified it.

Nick Rempel
  • 3,022
  • 2
  • 23
  • 31