oc 中怎么判断webview加载完成
展开全部
@protocol UIWebViewDelegate <NSObject>
@optional
- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType;
- (void)webViewDidStartLoad:(UIWebView *)webView;
- (void)webViewDidFinishLoad:(UIWebView *)webView;
上面是webView 的代理方法,你遵循代理之后 如果webVIew 加载完毕,将会调用
- (void)webViewDidFinishLoad:(UIWebView *)webView{
// do something... 请采纳,有问题请追问
}
@optional
- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType;
- (void)webViewDidStartLoad:(UIWebView *)webView;
- (void)webViewDidFinishLoad:(UIWebView *)webView;
上面是webView 的代理方法,你遵循代理之后 如果webVIew 加载完毕,将会调用
- (void)webViewDidFinishLoad:(UIWebView *)webView{
// do something... 请采纳,有问题请追问
}
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询