Hi Ramses,You should be able to do this. The only thing you have to do before hand is in ArcCatalog add tasks.arcgisonline to your services. You can do so with these steps: 1. Look in the Catalog Tree for GIS Services. 2. Expand that and select Add ArcGIS Server. 3. In the dialog, choose Use GIS services. Click Next.4. For the Server URL, type: http://tasks.arcgisonline.com/arcgis/services 5. Press ok. You should now see arcgis on tasks.arcgisonline.com in that GIS servers list. 6. Expand the connection and expand the locators folder. Select and click on the locator you want to use. 7. Copy the full location path from the Location bar at the top of ArcCatalog. 8. Use that path in this code sample: # Import system modules
import arcpy
# Set local variables:
address_table = r"C:\Data\Locations\geocodeONLINE\Addresses.dbf"
address_locator = r"GIS Servers\arcgis on tasks.arcgisonline.com\Locators\TA_Address_NA_10.geocodeServer"
geocode_result = r"C:\Data\Locations\geocodeONLINE\geocode_result.shp"
arcpy.geocodeAddresses_geocoding(address_table, address_locator, "Address Address VISIBLE NONE;City CITY VISIBLE NONE;State State VISIBLE NONE;Zip Zip VISIBLE NONE", geocode_result, "STATIC")
print "done!"
Additional code help for this tool can be found at: http://help.arcgis.com/en/arcgisdesktop/10.0/help/#/Geocode_Addresses/002600000006000000/