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 6155445
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T20:26:12+00:00 2026-05-23T20:26:12+00:00

I created an object that receives a coordinate and suppose to return a placemark

  • 0

I created an object that receives a coordinate and suppose to return a placemark after reverse geocoding it. Problem is that this method is a-synchronic, so I need a way to return the placemark once it was found. In my view controller I call this:

[getzip reverseGeocodeCurrentLocation:coordinate];

where getzip is an instance of an object that implements this (which is still empty in my case….):

- (void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFindPlacemark:(MKPlacemark *)placemark

Now, once I get into reverseGeocoder:didFindPlacemark, how can I return the placemark back to the viewcontroller?

I tried to do the same thing as I saw in some examples being done with LocationManager, where a locationUpdate method is being called from locationManager:didUpdateToLocation:fromLocation, and implementing the locationUpdate in the viewcontroller, but it did not work. In other words, I did that:

- (void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFindPlacemark:(MKPlacemark *)placemark
{
[self.delegate setPlacemark:placemark];
}

and implemented setPlacemark in the viewcontroller, but it doesnt get to setPlacemark from some reason (BTW, the placemark is correct once I call setPlacemark:placemark within reverseGeocoder).

Thanks!

  • 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-23T20:26:13+00:00Added an answer on May 23, 2026 at 8:26 pm

    As per your comments, self.delegate is nil when [self.delegate setPlacemark:placemark]; in reverseGeocoder:didFindPlacemark: is executed. Therefore, nothing happens.

    You must set the delegate property to your view controller before reverseGeocoder:didFindPlacemark: gets called. If the variable getzip in your view controller is an instance of the class that implements reverseGeocoder:didFindPlacemark: (GetZipCode?), you would do this in your view controller:

    getzip.delegate = self;
    

    As I said in my comment, by making your view controller conform to the GetZipcodeDelegate protocol means your view controller can be the delegate because it responds to the messages that the object that is delegating will potentially send to its delegate. It does not mean that it is the delegate.

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

Sidebar

Related Questions

I have a stdClass object created from json_decode that won't return the right number
I have created a method that should ideally take a single Account object and
I've created a object that I'd like to have accessible from wherever the request-object
All of our reports are created from object graphs that are translated from our
I have an object that hasn't been created yet (so it has no ID),
I have an ExpenseType object that I have created with the following migration: class
I'd like to be able to create an object that is created like a
i have created an IE band object (toolbar) that is working well. however, when
because obj, the playingCard object is created inside a nested for loop does that
Okay I'm totally confused on this one. I have a script that receives a

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.