Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [error-000539]

Use this tag for Questions which are related to the "000539" error returned by ArcGIS Desktop and ArcGIS Pro.

13
votes
8answers
32k views

Removing return/newline (\n) character from Field using Python and Field Calculator?

I have a geodatabase table with a field that I'm trying to remove return characters (new line). I found this post (How can I remove (chomp) a newline in Python?) of how to do it, however it is not ...
3
votes
1answer
5k views

Why does Raster Calculator (RasterCalculator_sa) give ERROR 000539 in ArcPy?

I am getting a not executed error for a raster calculator. Here is part of the output: File "C:\projectTemp\FloodAnalysis\floodxsectionanalysis.py", line 107, in makeSeemless arcpy....
4
votes
1answer
2k views

Why is arcpy.CalculateField_management() writing 1899-12-30 00:00:00 instead of expected date?

I'm using ArcGIS 10.3.1 for Desktop to test before writing an answer to Entering date with arcpy.GetParameterAsText()? I have written the test code below that I am running against a test feature class ...
2
votes
2answers
3k views

Error msg “Name is not defined” when trying to populate a field with the shape file name

I am trying to populate a field with corresponding file name. For example, if the file name is Route1.shp then the field value will be Route1 as well. However my code is not working. Can you please ...
2
votes
1answer
1k views

Calculating centroids of polygon using ArcPy?

I am trying to calculate the centroids of a polygon and add the x- and y-coordinate to their respective fields: arcpy.env.workspace = r"C:/..." input_fc = "shapefiles/precincts_v.shp" arcpy....
1
vote
1answer
2k views

Getting Error 000539 from Raster Calculator?

I am new to Arc and 10.2 but can not seem to figure out why this won't work. Executing: RasterCalculator Con(("SLOPE_SLO.tif" >= .015) & ("SLOPE_SLO.tif" <= .15,1,0)) D:\GEOG_480\Final2\...
1
vote
1answer
1k views

ArcGIS Raster Calculator error 000539 ImportError: No module named numpy?

I am running ArcGIS 10.2.1 on Win7 64bit. I have finished doing an NDVI, and after defining a vegetation presence threshold at 0.05, opened the Raster Calculator (via Map Algebra in the Arc Toolbox) ...
1
vote
1answer
240 views

Calculating centroid latitude in ArcMap throws error 000539 in Arcpy?

I can create a centroid latitude field in ArcMap10.1 using "Calculate Geometry..." in the attribute table, but when I try the same thing using: arcpy.CalculateField_management(bins_WGS84, "cent_lat", ...
4
votes
1answer
1k views

Scale raster in ArcGIS using raster calculator

I have a raster with values ranging from 0 to 8991130624. This raster is actually the result of a cost distance analysis. I want to scale the raster to range from 0 to 1 and take the inverse? so ...
3
votes
1answer
9k views

ArcGIS Raster Calculator fails with Error 000539

I have been using Raster Calculator in ArcMap 10.2, today it started returning error 000539 for all actions. Previously it had worked fine. I have not made any change ot my ArcGIS, Python, or Windows ...
2
votes
1answer
381 views

if/then with VBScript in ArcGIS Field Calculator giving Error 000539: SyntaxError: invalid syntax?

What is wrong with this VBscript in the field calculator? ColumnC= if [ColumnB] > 0 then [ColumnC] = [ColumnA] / [ColumnB] endif Each time I receive this syntax error message: Error ...
2
votes
1answer
2k views

ArcMap raster calculator error 000539

Using ArcMap 10.3, I am trying to perform map algebra on a raster with 2013 annual PRISM precipitation for the U.S. (http://prism.oregonstate.edu/recent/). The raster has 1 band an is floating point. ...
1
vote
2answers
666 views

Entering date with arcpy.GetParameterAsText()?

I want to allow users to enter a date as a parameter through a dialog window in a toolbox script. I have obviously defined the field with a "Date" data type but something is wrong with the formatting....
1
vote
3answers
2k views

Using Raster calculator in Modelbuilder ArcGis 10

I am using Modelbuilder to calculate several rasters with different parameters for each grid cell. One of the final steps is to calculate the log of one of the rasters using Raster calculator. ...
1
vote
1answer
336 views

Embedded quotes in arcpy.CalculateField_management expression

I'm using arcpy.CalculateField_management to populate a field. The expression: "'https://anystate.gov/someportal/DisplayQueryResults.aspx?Prompts=Spill%20Number="!ID!"&Database=OfficeDocs&...
1
vote
1answer
50 views

CalculateField_management, python Toolbox

I am trying to fill a field and I am using arcpy's CalculateField_management function. I want to fill the new field with the name of the shapefile, so I am using arcpy.Describe. But when I run the ...
1
vote
2answers
679 views

Avoiding error 000539 from code block in Calculate Value tool?

I do not have a very good understanding of python and have attempted to write a code block so that my model will skip rasters that do not contain any information and continue the process with rasters ...
1
vote
1answer
754 views

Raster Calculator error

I'm trying to use the Raster Calculator inside ModelBuilder to get rid of null values, but I'm hitting a snag. I'm using the expression: Con(IsNull("%temp_ras%"),FocalStatistics("%temp_ras%",...