Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3678820
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T03:23:13+00:00 2026-05-19T03:23:13+00:00

In my iPhone application, I’m showing a web page in webview. I implemented the

  • 0

In my iPhone application, I’m showing a web page in webview.
I implemented the delegate method as follows:

- (void)webView:(UIWebView *)webView didFailLoadWithError:(NSError *)error
{
    UIAlertView* alert = [[UIAlertView alloc] initWithTitle:@"Error" message:@"Error loading the requested URL" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil];
    [alert show];
    [alert release];
}

When ever I open a URL and loaded half page, i’m immediately clicking some other link in the web page. At that time also, this delegate method is being called.
How should I prevent to call delegate method when web page is loaded half and URL link is clicked.

Or some other solution can be to call stopLoading when some URL is clicked. How can I do that?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T03:23:13+00:00Added an answer on May 19, 2026 at 3:23 am

    How should I prevent to call delegate method when web page is loaded half and URL link is clicked.

    You can’t really stop the method from being called – but you might be able to check the properties of the error object to determine what kind of error you got.

    Or some other solution can be to call stopLoading when some URL is clicked. How can I do that?

    You can use webView:shouldStartLoadWithRequest:navigationType: which will be called whenever the user takes some kind of navigation action (e.g. clicks a link, submits a form etc. You can use navigationType to determine what the action was). It should be possible to call stopLoading from there (though the webView might still call the webView:didFailWithError: method, I’m not sure… see the first part on how you can deal with that).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my iPhone application... Could not call the delegate method ... Here is my
I have an iPhone application where i'm showing a settings page using modal view
my iphone application crash after raising 4 warnings of low memory, instruments is showing
My iphone application is showing strange behavior when rotating: a gap appears between the
In my iPhone application, on login to web services I get a session ID
I'm developing an iPhone application. The application access some web service that aboug other
My iPhone application connects to my PHP web service to retrieve data from a
My iPhone application continuously communicate with a web server. So in case of a
My iPhone application downloads large files from the internet (videos, for instance). I'd like
My iPhone application has several views and some viewControllers for that views. I need

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.