6

I am having difficulties in finding a way to use the input path and set is as the output path for a simple Copy Features tool. I use the substitution by the workspace but it outputs the results into the default ArcGIS folder.

I am not sure how to set the workspace to hold the path of the input feature class. As the input feature class is a parameter, I cannot use a hardcoded path. Please see below:

enter image description here

6

In the first example, you can parse the path and call %Value%. In the second example (which may not apply in your case), you can write intermediate files to in_memory workspace--thus, eliminating the need for parsing the path and possibly eliminating the need for the Copy Features tool.

enter image description here

enter image description here

  • Many thanks - This is what I am looking for. but I cannot find the Parse Path tool? How to add it to the model builder? – meryloo May 13 '13 at 13:59
  • 1
    Right click on the ModelBuilder screen > Model Only Tools > Parse Path – Aaron May 13 '13 at 14:03
  • 1
    To make sure the parse path runs first, connect "Value" to the "Copy Features" tool as a precondition. – Curtis Price May 13 '13 at 17:17
2

Use the Parse Path tool (only available within Model Builder) on the input features, using the 'PATH' option, and name the output 'workspace' to get it to work with your current Copy Features settings.

  • Many thanks - This is what I am looking for, but I cannot find the Parse Path tool? How to add it to the model builder? I can easily add other tool, for example, Add Fiel via the Search tab, but not the Parse Path – meryloo May 13 '13 at 14:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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