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

  • Home
  • SEARCH
  • 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 3440310
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T08:25:02+00:00 2026-05-18T08:25:02+00:00

I have a MKMapView with scrolling and userInteraction disabled within a UITableViewCell . The

  • 0

I have a MKMapView with scrolling and userInteraction disabled within a UITableViewCell. The desired effect (effectively a static image of the map in a certain position) works really well but when the MKMapView drifts on and off screen (scrolling) it reloads the map, which occasionally causes the app to crash. I have loaded the custom UITableViewCell in like any other UITableViewCell in cellForRowAtIndexPath:

if(indexPath.section == 0 && indexPath.row == 0)
{
    MapTableViewCell *cell = (MapTableViewCell *)[tableView dequeueReusableCellWithIdentifier:[NSString stringWithFormat:@"%@Map", cellIdentifier]];

    if(cell == nil)
    {
        cell = [[[MapTableViewCell alloc] initWithFrame:CGRectZero reuseIdentifier:cellIdentifier] autorelease];
    }

    NSArray *topLevelObjects = [[NSBundle mainBundle] loadNibNamed:@"MapTableViewCell" owner:self options:nil];

    for(id currentObject in topLevelObjects)
    {
        if([currentObject isKindOfClass:[UITableViewCell class]])
        {
            cell = (MapTableViewCell *)currentObject;
            break;
        }
    }

    return cell;
}

I’ve found out that with this current method, if you let the map image load before moving the UITableView then it’s OK. But if you move it off the screen before it’s finished loading then it will crash! 🙁

I will just point out that I do not want to be able to control the map in any way or show any annotations on it. I did try to screenshot a map view, hide it from screen and display that screenshot as a UIImageView in the UITableViewCell but this wasn’t fast enough!

EDIT: Updated code. This is the full code for this method. Is my custom TableViewCell alloc incorrect here?

  • 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-18T08:25:02+00:00Added an answer on May 18, 2026 at 8:25 am

    Thanks to tc for the answer (the comment above).

    What was required was for me to release the MKMapView in the custom UITableViewCell dealloc method.

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

Sidebar

Related Questions

I have a custom UITableViewCell set up with a MKMapView set up within the
I have MKMapView with MKPlacemark on it. When showing the map, I'm showing place
We have a MKmapView with a bunch of Image Annotation where each Image annotation
I have an MKMapView which allows the user to scroll the map around. Later,
I have a MKMapView and in the Map View Show User Location is set.
I'm working with MKMapView and have plotted several points on the map. I have
I have a screen on my map in MKMapView. How can copy this screen
I have a MKMapView in my iOS application, and would like to add the
I have a MKMapView annotation object that has a right callout accessory detail disclosure
I have a MKMapView & I use it to display user's current location. It

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.