I already checked the behavior on activity indicator view setting and coded it on a view controller..But still it keeps on spinning...What would be the problem?
I added this
@IBOutlet var Loadebest: UIActivityIndicatorView!
and this
func webViewDidStartLoad(_ : UIWebView) {
Loadebest.startAnimating()
NSLog("Webview is working")
}
func webViewDidFinishLoad(_ : UIWebView) {
Loadebest.stopAnimating()
NSLog("Webview stopped working")
}
But nothing happens...what could be the problem?
Check in storyboard, you have given delegate to webview.
If you haven't given delegate to webview then webViewDidFinishLoad
will not call and it will not hide spinner.