Get the interactive feature set (user click input) file path

220
0
06-21-2022 09:42 AM
DougZietz1
New Contributor III

I am using a feature set variable as user input in a model to create the center point for lines and polygons that I generate later in the model. Everything else in the model works as expected except every time I run the model, it creates a feature class in my gdb that I need to discard at the end of the model.

I can use Delete with the Feature Set as input which gets rid of the Feature Set but the newly generated "Points" or "Points_n" Feature Class(es) are not targeted. I have been trying to parse the path but the Parse Path tool and Calculate Value using os.path.dirname(), os.path.basename(), etc. all return nothing. My workaround is to run the tool once, drag the Points feature class into the model and run it again with the feature class referenced as a place holder but I don't think that will work when the tool gets published as either a web tool or geoprocessing tool. Is there another way to clean up this data? Everything else is run as in_memory.

 

0 Kudos
0 Replies