I wanted to know if it would be able to create a pull to refresh feature in ios using swift. I know how to do it when refreshing a table view but is it possible to do it without a table view just in a regular view controller ?
Asked
Active
Viewed 1,655 times
2 Answers
2
Yes, You can easily do it using UIScrollView
as UITableView
is subclass of UIScrollView

Nilesh Patel
- 6,318
- 1
- 26
- 40
-
how would i set up the scroll view in this case – sauly Jun 06 '16 at 02:41
-
Refer http://stackoverflow.com/questions/14905382/can-i-use-a-uirefreshcontrol-in-a-uiscrollview – Nilesh Patel Jun 06 '16 at 02:45
-
don't forget to enable bounce on your scrollview as I forgot. hope this helps – koceeng Apr 05 '19 at 06:45
0
Yes you can. As Nilesh Patel pointed it, it can be done using a scrollview; but also any kind of UIView would do it.
To do it on other views than UIScrollview, make your view draggable move uiview with finger
Simply allow your view to be dragged, and detect the appropriate condition: