• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [iOS] Sub Class MKPlacemark - Identifying each Placemark
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [iOS] Sub Class MKPlacemark - Identifying each Placemark


  • Subject: Re: [iOS] Sub Class MKPlacemark - Identifying each Placemark
  • From: banane <email@hidden>
  • Date: Sat, 11 Sep 2010 10:00:44 -0700

I stored my coordinates lat/long in an NSMutableDictionary. I call
them up upon load. Not sure if this helps- but I created something
called "headlinekey" which is the key to the dictinoary and the short
headline on the annotation.

for(NSString *headlineKey in [eDict allKeys]){
		float theLat = [[latDict objectForKey:headlineKey] doubleValue];
		float theLong = [[longDict objectForKey:headlineKey] doubleValue];

		CLLocationCoordinate2D theCoordinate;
		theCoordinate.latitude = theLat;
		theCoordinate.longitude = theLong;

		AddressAnnotation *theAnnot = [[AddressAnnotation alloc]
initWithCoordinate:theCoordinate andWithText:headlineKey
andWithSubtext:[eDict objectForKey:headlineKey]];
		//AddressAnnotation *theAnnot = [[AddressAnnotation alloc]
initWithCoordinate:theCoordinate andWithText:headlineKey];
		[self.mapView addAnnotation:theAnnot];

	}

On Sat, Sep 11, 2010 at 3:23 AM, Philip Vallone
<email@hidden> wrote:
> Hi,
>
> I am need of some advice. I have a MKMapView which allows users to add a bunch of MKPlacemark's that I've subclassed. How can I uniquely identify each placemark so I can store or retrieve information about that placemark?
>
> Thanks for help.
>
> Phil
>
>
>
>
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: [iOS] Sub Class MKPlacemark - Identifying each Placemark
      • From: Philip Vallone <email@hidden>
References: 
 >[iOS] Sub Class MKPlacemark - Identifying each Placemark (From: Philip Vallone <email@hidden>)

  • Prev by Date: Re: Inactive Window Receives Mouse Events
  • Next by Date: Re: Inactive Window Receives Mouse Events
  • Previous by thread: [iOS] Sub Class MKPlacemark - Identifying each Placemark
  • Next by thread: Re: [iOS] Sub Class MKPlacemark - Identifying each Placemark
  • Index(es):
    • Date
    • Thread