lhq0837

Use inline variable subsitution to set INPUT data path and name in model builder

Discussion created by lhq0837 on Nov 22, 2012
Latest reply on Dec 11, 2012 by lhq0837
Is it possible to use inline variable subsitution to set the INPUT path and name of layers which are needed in the second half of a model?

Please see the attached model. What I want to do is:
1. For each feature class in the workpace, I want to select the features intersecting with the area of interest, then export them to a new feature class.
2. I want to apply existing symbology layers of the original feature class to each of the new feature class respectively. I make sure the symbology layers has the SAME NAME as the original feature class.
3. Package the new feature class and the symbology layer into a layer package, so that I can distribute the data with symbology to other people

I set the path and name of the symbology layer variable to be:   %workspace%\%Name%.lyr   , assuming that all the values of Name variable in earlier part of the model can be picked up here one by one.

But I got ERROR 000732: symbology layer: Dataset %Workspace%\%Name%.lyr does not exist or is not supported

Am I on the right track? Can I use inline variable substitution for INPUT path and names, instead of the usual OUTPUT path and name?

Your help is much appreciated!!!

Christina Li
Spatial Analyst
Gold Coast City Council
Queensland, Australia

Outcomes