Path to file in app bundle?

Hello everyone, long time learner first time poster.

I’m working on an ASOC app that needs to choose the image an NSImageCell displays depending on what kind of external drive is attached. I have several .icns files loaded into the project, and would just use something like:

ThisImageCell’s setImage_(DriveIcon)

…assuming “DriveIcon” was a path to one of these icons I have in my project.

Is there a way I can reference a file inside the app bundle using Applescript or a POSIX path? Or do I have to venture into the cold, dark world of ObjC and big boy coding?

Sorry for the poorly phrased question, and thanks for any input you might have!

MJ

For images, it’s simple:

set driveIcon to current application's NSImage's imageNamed_("image name") -- no extension needed
ThisImageCell's setImage_(driveIcon)

Thanks Shane! Appreciate it!