AnsweredAssumed Answered

Python code ERROR 000670

Question asked by ccezar on May 12, 2014
Latest reply on Jun 6, 2014 by ccezar
Hi,
I'm learning to write scripts and I have now some problem.

import arcpy

arcpy.env.workspace = "c:/wtyczka/"
arcpy.env.overwriteOutput = True
outWorkspace = "c:/wtyczka/"

#dane
Wybor_gminy = "'Wyszków'"
Warstwa_zabudowy = arcpy.GetParameterAsText(0)
Bufor_od_zabudowy = arcpy.GetParameterAsText(1)
Warstwa_sieci_drog = arcpy.GetParameterAsText(2)
Bufor_od_sieci_drog = arcpy.GetParameterAsText(3)
Warstwa_sieci_kolejowej = arcpy.GetParameterAsText(4)
Bufor_od_sieci_kolejowej = arcpy.GetParameterAsText(5)
Warstwa_inna = arcpy.GetParameterAsText(6)
Bufor_od_inna = arcpy.GetParameterAsText(7)
Warstwa_inna_1 = arcpy.GetParameterAsText(8)
Bufor_od_inna_1 = arcpy.GetParameterAsText(9)
gminy = "c:/wtyczka/gminy_92.shp"
gmina = "c:/wtyczka/gmina.shp"
selekcja = '"GMINA"'+ " = " + "'Wyszków'"
lista = []

# Local variables:
zabudowa_clip = Warstwa_zabudowy
zabudowa_clip_bufor = zabudowa_clip
drogi_clip = Warstwa_sieci_drog
drogi_clip_bufor = drogi_clip
kolej_clip = Warstwa_sieci_kolejowej
kolej_clip_bufor = kolej_clip
inna_clip = Warstwa_inna
inna_clip_bufor = inna_clip
inna1_clip = Warstwa_inna_1
inna1_clip_bufor = inna_clip

#selekcja
arcpy.Select_analysis(gminy, gmina, '"GMINA" = \'Wyszków\'')

# Process: Clip zabudowa
if arcpy.Exists(Warstwa_zabudowy):
arcpy.Clip_analysis(Warstwa_zabudowy, gmina, zabudowa_clip, "0") - line 41
else:
print "false"

When I'm trying run this stript in ArcMap is an ERROR 000670: output Output Feature Class is same as input Input Features
Failed to execute (Clip).
I don't know why because input and out put Features has other names.

Please help! :)

Outcomes