Community of VE/MapPoint Users and Developers
This is a discussion on Getting Lat/Lon from a given address within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; I use this routine in my application: Private Sub Befehl0_Click() Dim objApp As New MapPoint.Application Dim objFindResults As MapPoint.FindResults objApp.Visible ...
| |||||||
| Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| Getting Lat/Lon from a given address Private Sub Befehl0_Click() Dim objApp As New MapPoint.Application Dim objFindResults As MapPoint.FindResults objApp.Visible = False objApp.UserControl = True 'Erstes Ergebnis der Suche ausgeben Set objFindResults = objApp.ActiveMap.FindAddressResults("Römerstraße 12", "Düren", , , "52349", geoCountryGermany) MsgBox "Das erste Element in der Ergebnisliste lautet: " _ + objFindResults.Item(1).Name objApp.Application.Quit End Sub But instead of the name of I would like to get back Lat/Lon. Is this possible? Ralf |
| |||
|
Sorry but can you help me again? I´m not able to call the function CalcPos. Here is my routine: Private Sub Befehl0_Click() Dim MPApp As New MapPoint.Application MPApp.Visible = True MPApp.UserControl = True Dim oMap As MapPoint.MAP, oLoc As Object, Strasse As String, Plz As String, stadt As String Dim oPin As MapPoint.Pushpin Dim objResults As MapPoint.FindResults Dim strRevAddress As String Dim lat As Double, lon As Double Set oMap = GetObject(, "MapPoint.Application").ActiveMap Strasse = "Römerstraße 12" Plz = "52351" Ort = "Düren" Set oLoc = oMap.FindAddressResults(Strasse, Ort, , , Plz, geoCountryGermany) Call CalcPos(oMap, oLoc.Location, lat, lon) MsgBox oLoc.Item(1).Name & lat & " " & lon End Sub I allways get an error. |
| |||
|
For the second argument of calcpos try using a mappoint.location object. Define for instance the following dim oLoc as mappoint.location then do everything else the same and in the calcpos call just use oLoc instead of oLoc.location hope this works |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| odd and even address | chris2 | MapPoint 2006/2009 Discussion | 1 | 05-24-2006 11:07 AM |
| Anyone willing to look up an address for me? | Anonymous | MapPoint 2006/2009 Discussion | 11 | 02-07-2004 07:09 PM |
Catered Chalet Ski Holidays
Looking for catered chalet ski holidays? Your search is over! Here at Holiday Hypermarket you can choose your style of accommodation with ease.
Honeymoon Holidays
Book your Honeymoon holiday with Travel Counsellors. A personal advisor will help you plan the perfect honeymoon holiday.
Cheap Holidays to Turkey
If you’re looking for cheap holidays to Turkey then dealchecker.co.uk is the place for you! Our search helps you see real prices from the UK’s top holiday companies all in one go.
Holidays in Dubai
Holidays in Dubai are an eclectic mix of the ancient and the modern. Discover an oasis of luxury amid the Arabian desert. Book here now!
Cheap Cyprus Holidays
Finding cheap Cyprus holidays can be difficult unless you know where to look and where to book. With ulookubook.com you can conduct a simple search to find the latest holiday deals to your particular destination.
Holidays Package
Make use of our service at Travel.co.uk to compare holidays. We can find you a package deal that will delight you.
Fuerteventura Holidays
Visit one of the closest Canary Islands to Africa! Book Fuerteventura holidays at On The Beach!