using GoogleMaps.LocationServices; using System; namespace Coordination { public static class LocationService { public static Location Location (string address) { var locationService = new GoogleLocationService(); var location = new Location(); try { var point = locationService.GetLatLongFromAddress(address); if (point != null) { location.Latitude = point.Latitude.ToString(); location.Longitude = point.Longitude.ToString(); } } catch(Exception ex) { Console.WriteLine(ex.Message); } return location; } } }
var point = locationService.GetLatLongFromAddress(address);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)