Thanks Dan. Your alternative makes sense in that I’d be referencing the path directly. But my code is a bit cumbersome. I need eval() to convert my strings into JavaScript expressions. And it does perfectly. But what happens is it pulls the eval() statement into a separate scope away from everything. And it doesn’t even get to listen to the if conditional.
In extendscript it actually forces a new window open, placing the new ‘string’ as a JavaScript statement, evading the if conditional. I’ll have to figure another way. Thank you!