|
POST
|
Hi Mitt, I doubt you can define a parameter as values in a field. You can pass a shapefile and field as input parameter. Refer this blog Create a list of unique field values | ArcPy Café , get a list of values in your script and loop through the values.
... View more
09-25-2014
10:24 PM
|
1
|
0
|
601
|
|
POST
|
, in your shapefile name is creating issue with clip. Interestingly if your shape file name is GISTRAN.Trans_330kV_OH_CarrierKONDININ, SHIRE OF.shp (with period) it's slipping through . is creating issue with make feature layer It's better to avoid special characters in your shape file name all together. Change your LGA name to Shire of KONDININ without , separator.
... View more
09-25-2014
06:58 PM
|
0
|
0
|
3608
|
|
POST
|
Hi Mitt, It's the period character in your shapefile name that's creating the issue. Change line 43 in above code to replace . with _ basefileName = arcpy.Describe(Struc).baseName.replace('.','_') + LGA
... View more
09-25-2014
06:03 PM
|
1
|
3
|
3608
|
|
POST
|
Hi Mitt, Sorry, Get Count accepts a layer input. We need to create a layer from the shapefile and pass it as input to the get count tool. Use below code, tested. Mind the line intents
arcpy.env.workspace = r"C:\tempdelete\Test_road"
shapefiles = arcpy.ListFeatureClasses()
for shapefile in shapefiles:
layerName = arcpy.Describe(shapefile).baseName
arcpy.AddMessage(layerName)
arcpy.MakeFeatureLayer_management (shapefile, layerName)
arcpy.AddMessage(arcpy.GetCount_management(layerName).getOutput(0))
if int(arcpy.GetCount_management(layerName).getOutput(0)) == 0:
arcpy.Delete_management(shapefile)
... View more
09-25-2014
05:19 PM
|
0
|
6
|
3608
|
|
POST
|
Hi Mitt, It should be if int(arcpy.GetCount_management(shapefile).getOutput(0)) == 0: have a look at example 2 ArcGIS Desktop
... View more
09-25-2014
02:51 AM
|
0
|
8
|
3608
|
|
POST
|
Hi Richard, Have you got fields POP07_SQMI, POP2000, POP00_SQMI in your layer. can you post a screenshot of your infowindow output?
... View more
09-24-2014
08:56 AM
|
0
|
1
|
1353
|
|
POST
|
Hi Jeoff, Try arcpy.CalculateField_management(mapLyr2, "Jurisdicti", "\"{0}\"".format(tName), "PYTHON")
... View more
09-24-2014
08:46 AM
|
1
|
0
|
559
|
|
POST
|
Hi Richard, feature.setInfoTemplate(infoTemplateUtilities); should work. for changing the backgrounf color use .esriPopup .titlePane{ background-color: #ffffff }
... View more
09-24-2014
08:17 AM
|
0
|
4
|
1353
|
|
POST
|
Hi Michael, wmsLayer.setVisibleLayers(["-1"]) does the trick. Test with this ArcGIS API for JavaScript Sandbox sample
... View more
09-24-2014
05:42 AM
|
0
|
1
|
1614
|
|
POST
|
Hi Thomas, I suspect it's your locale setting. I can reproduce the same error if i set my locale explicitly to German_Germany, may be try explicitly setting your locale as locale.setlocale(locale.LC_ALL, 'English_US') Below is the code that produced this error.
import arcpy, datetime, locale
layer = arcpy.GetParameter(0)
arcpy.AddMessage(layer)
locale.setlocale(locale.LC_ALL, 'German_Germany')
with arcpy.da.UpdateCursor(layer, ["ddMMMYYYY", "YYYY_MM_dd"]) as UCursor:
for row in UCursor:
origDate = datetime.datetime.strptime(row[0], '%d%b%Y')
row[1] = datetime.date.strftime(origDate, '%Y-%m-%d')
UCursor.updateRow(row)
... View more
09-24-2014
05:37 AM
|
1
|
1
|
2482
|
|
POST
|
Hi Najad, Have look at AddTextElement method in this sample ArcObjects 10 .NET SDK Help . Iterate through your polygon vertices by casting it as IPointCollection to get vertex geometry.
... View more
09-21-2014
07:46 PM
|
0
|
1
|
1249
|
|
POST
|
Hi Euan, You can use Iterator to iterate through your feature selection. ArcGIS Desktop . Use object ID as your fields, then you can access the object ID for each iteration as %Value%. Set your buffer feature class name as <<Feature Dataset>>\output_%Value%
... View more
09-21-2014
07:14 PM
|
0
|
0
|
3869
|
|
POST
|
Hi Marc, Is your print task execution mode set to asynchronous? May be try setting it to synchronous mode and try the print widget.
... View more
09-19-2014
06:15 AM
|
0
|
0
|
994
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 08-31-2014 06:04 AM | |
| 1 | 09-25-2014 06:03 PM | |
| 1 | 09-16-2014 06:15 PM | |
| 1 | 10-08-2014 03:50 AM | |
| 1 | 08-25-2014 08:33 PM |
| Online Status |
Offline
|
| Date Last Visited |
11-11-2020
02:24 AM
|