You are very welcome Martin,
I didn't have to use the extra os.path.fullPath(StartupPath) on my MacOs laptop, I'm glad this is working for you in all cases you need it.
Also and to be complete, my colleague Florencia pointed me to an even more efficient way to achieve what you want (in one line only, how could I miss that!)
let StartupPath = base.Application.getProgramDir()
Best
Laurent