Getting path to resources

I added a build step to copy an executable file into my resource folder.

Applies to: Both
Subdirectory: dcmtk_mac
Destination: Resources Folder

at run time I’m trying to get the path to that folder.

f = app.ExecutableFile
path = f.ShellPath

While debugging this is what is returned by f.ShellPath

/private/var/folders/j9/m67_1bwd2qg14r3snb_2m7w80000gn/T/TemporaryItems/FindAndUpdateDatabase.debug.app/Contents/MacOS/FindAndUpdateDatabase.debug

however my resources are here:

/private/var/folders/j9/m67_1bwd2qg14r3snb_2m7w80000gn/T/TemporaryItems/FindAndUpdateDatabase.debug.app/Contents/Resources/dcmtk_mac

What am i suppose to do to do this properly?

did you try SpecialFolder.Resources???

plus you resources are NOT at app.executable path… they are below that

Thank you Dave!

app.ExecutableFile.Parent.Parent.Child(“Resources”). Specialfolder.Resources is newer

I’d say SpecialFolder.GetResource(“dcmtk_mac”) is even shorter :wink:

If you’re using an older version of Xojo, the TPSF module is especially helpful.