You've gone off on a new tack. That code is not related to any external file source data or file paths that you've been talking about previously.
I would be doing what you describe you want in a very different way. I would use an embedded xml file and then use linked Content Controls to display the related data. For each 'template' I would set up a single Word template which contains a series of building blocks - one for each document type. You would then insert one of the building blocks (to populate the xml file) and could then replace the content with any of the related Building Blocks to create each of the document instances.
See
https://gregmaxey.com/word_tip_pages...rol_tools.html for a different way of setting up the file.