Xojo.IO.SpecialFolder.GetResource

From Xojo Documentation

Method

Xojo.IO.SpecialFolder.GetResource(name As Text) As Xojo.IO.FolderItem

Supported for all project types and targets.

Gets the specified file (by name) located in the Resource folder of the app's main bundle (Mac or iOS) or in the Resource folder on Windows, Linux and console apps.

Notes

Use a Copy Files Build Step to copy files into the Resource folder.

Exceptions

Sample Code

Gets a file that has been copied to the Resource folder:

Dim bundleFile As Xojo.IO.Folderitem
bundleFile = Xojo.IO.SpecialFolder.GetResource("AppDatabase.sqlite")