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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T03:26:13+00:00 2026-06-12T03:26:13+00:00

i added an annotation and in viewforannotation i set canshowcallout and selected the annotation

  • 0

i added an annotation and in viewforannotation i set canshowcallout and selected the annotation as well but it aint getting selected…

  -(void)locationManager:(CLLocationManager *)manager didUpdateToLocation:(CLLocation *)newLocation fromLocation:(CLLocation *)oldLocation{
    currentCoordinates = newLocation.coordinate;
 ParkPlaceMark *pa = [[ParkPlaceMark alloc] init];
        pa.coordinate = currentCoordinates;
        pa.title = @"POI";
        pa.title2 = @"CUrrent Locn";
        pa.subtitle = @"Drag and drop to adjust the position if necessary";
        [mapView addAnnotation:pa];
        [pa release];
   }
   - (MKAnnotationView *)mapView:(MKMapView *)map
        viewForAnnotation:(ParkPlaceMark*)annotation {

MKAnnotationView *test=[[MKAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:@"parkingloc"];
if([annotation.title caseInsensitiveCompare:@"POI"] == NSOrderedSame)
{
    test.annotation = annotation;

    test.userInteractionEnabled = YES;
    test.draggable = YES;
    //        test.pinColor = MKPinAnnotationColorRed;

    [test setImage:[UIImage imageNamed:@"marker3.png"]];
    [test setEnabled:YES];
    [test setCanShowCallout:YES];
    [test setDragState:MKAnnotationViewDragStateEnding animated:YES];
    [self.mapView selectAnnotation:test.annotation animated:YES];
    return test;
   }
  }
  • 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-06-12T03:26:15+00:00Added an answer on June 12, 2026 at 3:26 am

    I had added custom animation so

      [self.mapView selectAnnotation:test.annotation animated:YES];
    

    was not working . The correct code is :

      [self.mapView selectAnnotation:test.annotation animated:NO];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've successfully added a custom UILabel to an annotation callout, but am failing at
I added an event handler to the WebClient's DownloadProgressChanged event, but it never seems
In Scala 2.8.x, a new annotation ( @tailrec ) has been added that gives
I am attempting to set a map annotation to the user's current location. I
Please help me How I can resolved this problem. java.lang.IllegalArgumentException: already added: Ltwitter4j/Annotation; [2012-05-14
I have a mapView that has annotation added through JSON (feed is stored in
I am using MKMapView and have added a number of annotation pins to the
I have created an asp.net mvc 3 razor view and added data annotation attributes
I've developed a CXF web services with MTOM enabled. I've added an annotation to
I've added the [Required] data annotation to one of my models in an ASP.NET

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.