Create Feature

90
1
Jump to solution
09-25-2019 05:13 AM
jaykapalczynski
Frequent Contributor

I have a python script that I am accepting parameters from a GP Service 

The creation of the point works fine...

BUT regardless of what I specify for an XY if places the points off the coast of Ecuador

The FC is in UTM Zone 17N....

It does not matter if I hard code (-75.5, 38.5) or (1221066.25, 4014421.79) it still drops the point in the same location.

varItem = arcpy.GetParameterAsText(0)
varXCoord = arcpy.GetParameterAsText(4)
varYCoord = arcpy.GetParameterAsText(5)

#SNIP
# I set my workspace and FC, start editing, 
#SNIP

row_values = [( varItem, varXCoord ,varYCoord)]
print(row_values)

cursor = arcpy.da.InsertCursor(fc,['Item', 'PublicPrivate', 'SHAPE@Y', 'SHAPE@X'])
for row in row_values: 
    cursor.insertRow(row)

## Stop the edit operation.
edit.stopOperation()

## Stop the edit session and save the changes
edit.stopEditing(True)
0 Kudos
1 Solution

Accepted Solutions
jaykapalczynski
Frequent Contributor

I figured it out....its working now....sorry...I had the wrong Coordinate I was hard coding

View solution in original post

0 Kudos
1 Reply
jaykapalczynski
Frequent Contributor

I figured it out....its working now....sorry...I had the wrong Coordinate I was hard coding

0 Kudos