AnsweredAssumed Answered

ModelBuilder: Open shapefile using parsed filename

Question asked by kerouacesque on Jul 22, 2015
Latest reply on Jul 31, 2015 by kerouacesque

I'm trying to build a model that will iterate through a series of xyz text files, and clip each text file using a similarly named shapefile on a one-to-one basis. So example01.txt has a corresponding polygon shapefile, example01.shp, which will be used to clip it. So I've parsed out the filename, example01, but when I try to use that as the Clip Feature in the Clip tool, the model refuses to start, claiming that %filename%.shp does not exist. What am I missing? Is there a way to do this?

 

I've already tested a simpler model that will convert the text files to multipoint shapefiles, and that works on its own. But I can't get Arc to recognize that it needs to evaluate the filename variable prior to checking for the existence of the shapefile.

 

Thanks.

 

Model.png

Error.png

Outcomes