Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I am using iterate raster in modelbuilder to create hillshade and slope simultaneously for many rasters within one folder. My problem is when I name the output files. Whenever I use, %Name%, the model fails because the resulting output names include the file extension. If I use %n%, it only creates one file. Is there another way of naming output files where the original file name is retained but without the file extension?

share|improve this question

1 Answer 1

The Parse Path (ModelBuilder) should be able to meet your requirement.

The Parse Path tool parses the input into its file, path, name, or extension. The output can be used as in-line variables in the output name of other tools.

If not, then a diagram of your model and more details would be helpful to try and provide a more targeted Answer.

share|improve this answer
    
Oh thanks, it worked, however, when I tried to combine Parse path with calculate value (because I also need to remove the hyphen from my filename), the resulting outputs do not match the initial output. I'm still trying to figure it out –  user26845 Feb 12 at 8:28

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.