How do I remove all of the subviews from a UIScrollview?
I think you just have to be careful and not to delete the scroll indicator bars.
The code given by Adam Ko is short and elegant but it may delete the horizontal and vertical scroll indicators.
I usually do
for (UIView *v in scrollView.subviews) {
if (![v isKindOfClass:[UIImageView class]]) {
[v removeFromSuperview];
}
}
Suposing you don't have UIImageView's added to the scroll manually.