4Bart

List Map Services - Function Error

Discussion created by 4Bart on May 3, 2013
Latest reply on May 9, 2013 by mvolz47
Hi!

Using this tool looks so easy (acording to http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/ListMapServices/00s30000004s000000/), but it is not working for me :( ...

My code:
import arcpy
serviceList = arcpy.mapping.ListMapServices("http://sampleserver1.arcgisonline.com/arcgis/services","sampleserver1.arcgisonline.com")
for serviceName in serviceList:
    print serviceName


And Im still getting "IOError: Object: Connection error ?"... What is wrong? Can someone help, please?

eddit: version ArcGIS 10.0 SP5, Python 2.6.5, target ArcGIS Server 10.0 SP4 (I think)

Outcomes