Original User: luke.kaimHi Everyone,I think I am not understanding the logic, but what I want to do is make an if then statement. I want to create a file and then create another file. The code creates the first file, but does not create the second file. What am I doing wrong? def main():
try:
import arcpy, sys, traceback, os, string, locale,arcgisscripting
arcpy.env.overwriteOutput = True
from arcpy import env
env.workspace =r"C:\Users\Luke Kaim\Documents\University of Maine\Fall_2012\Volunteer Geographic Information\simalar"
outputVGIboundingbox= "VGIboundingbox.shp"
outputGNISboundingbox="GNISboundingbox.shp"
VGIFile = r"C:\Users\Luke Kaim\Documents\University of Maine\Fall_2012\Volunteer Geographic Information\simalar\polygon.shp"
GNIS_FC = r"C:\Users\Luke Kaim\Documents\University of Maine\Fall_2012\Volunteer Geographic Information\simalar\GNIS.shp"
if arcpy.Exists(outputVGIboundingbox):
arcpy.Delete_management(outputVGIboundingbox)
VGIboundingbox= arcpy.FeatureEnvelopeToPolygon_management(VGIFile,outputVGIboundingbox,"MULTIPART")
elif arcpy.Exists(outputGNISboundingbox):
arcpy.Delete_management(outputGNISboundingbox)
GNISboundingbox= arcpy.FeatureEnvelopeToPolygon_management(GNIS_Geom,outputGNISboundingbox,"MULTIPART")
Thank you in advanceThank you,Luke KaimThank youLuke Kaim (SIE)Lucas.Kaim@maine.edu(914)263-7866"Don�??t complain. Just work harder" (Randy Pausch).