Pictures in a project

I have an app that contains a lot of pictures. I have created a folder inside the project where I dragged all these pictures.

When I copy the project from my test environement to my production environment, I loose all the references to the pictures.

I have decided to save the project as a Xojo project instead of a binary project. I can see the structure of the project with all the folders. I have copied all the images into the right folder. When I copy the project in another environment, Still, I have to use the option Relocate to make available the image to the project .

Is there a way to make the picture in a project with a relative link within the project?

I have not found one, and I have asked this same question a few times over the past year or so.

What I do is move projects from my desktop to my laptop so I can work while traveling.
The only sollution I have found it to create a project directory on both computers with the same name

Thanks Dave,

The only other way I have found is to edit the project file and to change the links manually but I do not like it. It can corrupt this file.

Hi Dave,

Finally, there is no corruption.

Here are the steps.

You save your project as a xojo project (not binary nor XML).
When you look into the folder, you see a structure of folder.
In Xojo, you create a folder where you drag your pictures.
You copy your pictures into the physical folder (using Explorer in Windows or Finder for Mac)
You drag your pictures from Explorer into the picture folder.
You save your project.

Now, If you edit your project file (.xojo_project extension) with TextEdit or any text editor, you see that your pictures are listed and each one has a path.

If you decide to save your project on another folder, you create this folder, save your project and copy your pictures to the corresponding folder. The last step is to edit the project file and to change the path of each pictures (you can use the “Replace all” function in your Editor) and there you go.

How do you create a folder inside the project? My project has a lot of pictures and I struggle to find objects/forms/etc because that is what really matters in a developer point of view.

I just want to omit these images from that huge list of objects from the left side palette.

Create a folder inside Xojo itself? Just go to the dropdown menu: Insert, then Folder. Then you can drag those pics into the folder. Your project can still use and reference them the same way as before, they’re just more organized. I use this method myself, very helpful when you have a lot of images.

Much better now! Thanks.

The right click New Folder option is always disabled thats why I always ignored a second hunt at the top menus for the same.