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

  • SEARCH
  • Home
  • 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 4060344
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T15:19:34+00:00 2026-05-20T15:19:34+00:00

I am trying to parse out a Reverse Geo-location using Bing Maps. http://www.microsoft.com/maps/isdk/ajax/ Find

  • 0

I am trying to parse out a Reverse Geo-location using Bing Maps.

http://www.microsoft.com/maps/isdk/ajax/
Find Information > Reverse Find

If you look at the code, when you look up an address, you get this back

function _f1300044038369() {
    return {
        "d": {
            "__type": "Microsoft.VirtualEarth.Engines.Core.Geocoding.ReverseGeocodeResponse",
            "Results": [{
                "Name": "SW 35th Ave, Tualatin, OR 97062",
                "Type": 0,
                "BestLocation": {
                    "Precision": 0,
                    "Coordinates": {
                        "Latitude": 45.378872752189636,
                        "Longitude": -122.71288096904755
                    }
                },
                "Locations": [{
                    "Precision": 0,
                    "Coordinates": {
                        "Latitude": 45.378872752189636,
                        "Longitude": -122.71288096904755
                    }
                }],
                "BestView": {
                    "NorthEastCorner": {
                        "Latitude": 45.382735469760313,
                        "Longitude": -122.70554921472814
                    },
                    "SouthWestCorner": {
                        "Latitude": 45.37501003461896,
                        "Longitude": -122.72021272336696
                    },
                    "Type": 0,
                    "Center": {
                        "Latitude": 45.378872884129805,
                        "Longitude": -122.71288096904755
                    }
                },
                "Shape": null,
                "Address": {
                    "AddressLine": "SW 35th Ave",
                    "Locality": "Tualatin",
                    "PostalTown": "",
                    "District": "",
                    "AdminDistrict": "OR",
                    "PostalCode": "97062",
                    "CountryRegion": "United States",
                    "FormattedAddress": "SW 35th Ave, Tualatin, OR 97062"
                },
                "CountryRegion": 244,
                "MatchConfidence": 1,
                "MatchCode": 1
            }],
            "ResponseSummary": {
                "Copyright": "Copyright © 2011 Microsoft and its suppliers. All rights reserved. This API cannot be accessed and the content and any results may not be used, reproduced or transmitted in any manner without express written permission from Microsoft Corporation.",
                "StatusCode": 0,
                "AuthResultCode": 0,
                "ErrorMessage": null,
                "TraceId": "dc1c3b20-6345-484c-9662-4df504d8977e|SN1M001054"
            }
        }
    }.d;
}
if (typeof closeDependency !== 'undefined') {
    closeDependency('1300044038369');
}

The code I currently use parses the “Name” into it’s sections so that I can use it elsewhere.

function GetResults(locations) {
    if (locations) {
        for (var i = 0; i < locations.length; i++) {
            s = locations[i].Name;
            //
            var addressSplit = s.split(", ");
            addresscode = addressSplit[0]
            citycode = addressSplit[1]
            statezip = addressSplit[2]
            country = addressSplit[3]
            var statezipSplit = statezip.split(" ");
            statecode = statezipSplit[0];
            zipcode = statezipSplit[1];
            var loc_array = new Array();
            loc_array[0] = addresscode;
            loc_array[1] = citycode;
            loc_array[2] = statecode;
            loc_array[3] = zipcode;
            window.locationArray = loc_array;
        }
    }

I want to change the above code to use the section that has the addressline, location, postaltown, etc already.

  • 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-05-20T15:19:34+00:00Added an answer on May 20, 2026 at 3:19 pm
    function GetResults(locations) {
        var locations = locations.Results;
        if (locations) {
            for (var i = 0; i < locations.length; i++) {
                var addr = locations[i].Address,
                    loc_array = new Array()
                    addresscode, citycode, country, statecode, zipcode;
                //
                addresscode = addr.AddressLine;
                citycode = addr.Locality;
                country = addr.CountryRegion;
                statecode =addr.AdminDistrict;
                zipcode = addr.PostalCode;
                loc_array[0] = addresscode;
                loc_array[1] = citycode;
                loc_array[2] = statecode;
                loc_array[3] = zipcode;
                window.locationArray = loc_array;
            }
        }
    

    That’ll do what you want. But it’s not very nice practise. First of all – if you have multiple locations, each will overwrite the other. Second, this pollutes the window namespace which is not recommended.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Trying to parse out lat/lon from a google maps rss feed: $file = http://maps.google.com/maps/ms?ie=UTF8&hl=en&vps=1&jsv=327b&msa=0&output=georss&msid=217909142388190116501.000473ca1b7eb5750ebfe;
I am trying to parse out data from oodle.com api feed using the JSON.NET
I'm trying to parse some data out of a file using Perl & Parse::RecDescent.
I am trying to parse out sentences from a huge amount of text. using
I'm trying to write a regex that will parse out the directory and filename
Trying to parse an SQL string and pull out the parameters. Ex: select *
I'm trying to figure out how to parse a VCard to a Python dictionary
I am trying to figure out the best way to parse this comma delimited
Im trying to parse the string located in /proc/stat in a linux filesystem using
I am trying parse out 3 pieces of information from a String . Here

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.