Tag: google maps

My location button not appearing in view (Google maps SDK, ios)

Here is my mapViewController.m file: @interface MapViewController() @property (strong, nonatomic) GMSMapView* mapView; @property (weak, nonatomic) IBOutlet GMSMapView *subView; @end @implementation MapViewController – (void) viewDidLoad{ // Create a GMSCameraPosition that tells the map to display the // coordinate -33.86,151.20 at zoom level 6. GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:-33.86 longitude:151.20 zoom:6]; _mapView = [GMSMapView mapWithFrame:self.view.bounds camera:camera]; _mapView.myLocationEnabled […]

infowindow not displaying with marker in didTapAtCoordinate method

i am trying to show infowindow and marker both simultaneously. code -(void)set_markerOnMap:(double)lat longitude:(double)lon{ GMSMarker *marker = [[GMSMarker alloc] init]; marker.title = @”Location selected”; marker.position = CLLocationCoordinate2DMake(lat, lon); marker.snippet = @”Testing”; marker.icon=[UIImage imageNamed:@”red-pin.png”]; marker.map = self.MyMapView; [self.MyMapView setSelectedMarker:marker]; } – (void)viewDidLoad { [super viewDidLoad]; [self set_markerOnMap:21.214894 longitude:72.88087]; self.MyMapView.delegate=self; } above code is working fine and its […]

IOS – ObjC Google Maps Api Key

i just did everything right as mentioned here but Xcode still gives that error: Google Maps SDK for iOS cannot connect or validate APIKey: Error Domain=com.google.HTTPStatus Code=400 “The operation couldn’t be completed. (com.google.HTTPStatus error 400.)” UserInfo=0x8416b20 {data=<CFData 0x9187710 [0x27424d8]>{length = 145, capacity = 256, bytes = 0x3c48544d4c3e0a3c484541443e0a3c54 … 3c2f48544d4c3e0a}} 2013-09-01 15:04:04.902 MyApp[1357:12e03] Your key may […]

Button on Custom info Window not Receiving Action in ios

I am using Google Maps in iOS Application and have implemented a custom info window for showing title of a marker. Now, I added a button on that custom info window but my problem is that the button action method does not get called. CustomInfoWindow.h #import <UIKit/UIKit.h> @interface CustomInfoWindow : UIView @property (nonatomic,weak) IBOutlet UILabel […]

Google maps polyline not rendering perfectly

I am drawing polyline using latest google maps API for iOS. I am constructing polyline point by point but it is not rendering properly as when i zoom out the polyline vanishes(not in literal terms) from the map and when i zoom in it simply shows the line. This is how polyline appears when zoomed […]

iPhone App :show direction using Map

in My iPhone App How Can I show directions from current location to End Point? is there any built in component or facility available on iphone which can show maps and direction using GPS and built in compass?

Finding nearest places using GoogleAPI

I am developing an Iphone application in which i am using GoogleAPI to find the nearest Restrooms within 500 meters. But the thing i want to do is to find the places in sorted pattern starting from places whose distance is less from current location. Thanks.

Google Maps Info window's resizing based on the internal content

I’m creating custom Info Window using this method – (UIView *)mapView:(GMSMapView *)mapView markerInfoWindow:(GMSMarker *)marker based on the UIStoryboard using Autolayout. I expect that some of the internal views will be resized due to the actual text information will be received and the final size of the Info Window will be different from the view of […]

Efficiency of Google Geocoding with Dispatch Queue – How to Improve – iPhone

I have a Google Map view in my app which is populated with pins via geocoding. I am using the below code to create a dispatch queue which then queries Google for the longitude and latitude for each place in my app. The problem is that although the below code works to some extent, it […]

How to relocate or move the current location button on Google Maps SDK?

How would I move the current location button in objective-c to my preference? Right now, I have it enabled, but I have something blocking it in the bottom corner. Thanks