Hot answers tagged

4

Looks like you're trying to add data to the insert cursor one column at a time. Cursors think about the world one row at time. I recommend the following code. A few other notes... Python code runs in order, so make sure you declare your outpath variable before you set your env.workspace to outpath. Also, this code is going to create a shapefile with the ...


4

You can try to use a python script and use one of the two following modules. But think of it carefully as running a program out of a script can do many unpleasent things. import subprocess subprocess.call(['C:\\folder\\gams.exe']) import os os.system('"C:\\folder\\gams.exe"') Update as it is about a file of the type .gms: Check out the answers on this ...


3

You may use the Intersect tool and define POINT as output type. Computes a geometric intersection of the input features. Features or portions of features which overlap in all layers and/or feature classes will be written to the output feature class. output type: POINT - Point intersections will be returned. If the inputs are line or polygon, ...


3

Expanding on my previous comment... The problem with your statement is that the returned value from string.split is a list and the field you're trying to calculate into is a string, these types are incompatible so the parser ignores the value and sets the string to null. To turn a list into a string you need to use join: >>> a = "Johnny be good" ...


2

There is a Help page entitled Understanding script tool parameters that explains how to do this. You configure the Parameters on the tool dialog and then get them within your script using either arcpy.GetParameter() or arcpy.GetParameterAsText().


2

ArcGIS doesn't like fieldnames with spaces, or any other non-alphanumeric character for that matter (other than the underscore _) The Esri FAQ What characters should not be used in ArcGIS for field names and table names? says Eliminate any characters that are not alphanumeric character or an underscore. Do not start field or table names with an ...


1

Field in the Feature to Raster tool must be exposed as a model variable. Right click on the Feature to Raster tool >> Make Variable >> From Parameter >> Field Once you have done that you can then set Raster_%Field%


1

Try using the "Create "Index Grid Features" You can specify the size of the grid, and this way your data becomes indexed and can provide a performance boost when you have a large dataset like yours. Make sure you check this box as well: Now, all this will do is create a grid, so you can cut the polygons and join them to each grid. Couple of links about ...


1

No, you are not doing something wrong. Actually, a few minutes print time for a highly detailed vector basemap with maybe a few dozen vector layers, is not bad at all! The amount of processing needed to convert this to something printable, is quite considerable. The particular behaviour you are seeing, with repeated cycles of the same layer names appearing ...


1

Based off your code, it sounds like you're trying to disable a button rather than an entire toolbar. Instead of WTF_toolbar.enabled = False do fish_button.enabled = False to disable the button. Same goes for WTF_toolbar.enabled = True. More info here


1

Spline interpolation requires point feature class as an input to do interpolation. You can not use polygon or raster (as mentioned in you question) as an input to the spline tool. You need to have point data with z_field (numeric field).


1

Thanks to Hornbydd for the accepted answer. Below is the solution in C# in case it helps anyone. The method call to get to the label engine properties is slightly different than vba. IGeoFeatureLayer geoFeatureLayer = (IGeoFeatureLayer)featureLayer; geoFeatureLayer.DisplayAnnotation = true; IAnnotateLayerPropertiesCollection propertiesColl = ...


1

I have found that the error you receieved AttributeError: 'module' object has no attribute 'EnableDataReviewer_Reviewer' occurs in (at least) three situations. You don't have Data Reviewer installed - Data Reviewer is a separate install of ArcGIS Desktop; it is not installed by default. You don't have a Data Reviewer license - it appears that the ...



Only top voted, non community-wiki answers of a minimum length are eligible