I have an FME workbench which reads all of the TAB files in a folder and all of the subfolders and writes the paths of those TAB files as well as their type (NATIVE, RASTER, etc) to an Excel file.
The folder is a published parameter. What I would like to do is name the Excel file the same as the rightmost folder (I'm not sure what you'd call this) in the parameter.
For example, when the workbench is run, the user selects this folder:
The excel file would be GHI.xlsx
or if the user selects this folder:
The excel file would be DEF123.xlsx
I have tried many different ways to get this folder name. I tried creating a new parameter that builds the name but no luck. I've also tried setting the parameter as an attribute using the parameterFetcher then using the SubstringExtractor. However, I can't seem to get the start and end index set properly. This is what I've got in my substringExtractor: