I'm trying to make a report in QGIS, in the attribute table of my layer, I have a column named "picture1" filled with the relative path of a picture, that illustrate the feature.
In the report, I did a "Field group section" with my layer and a map controlled by report. Now I would like to add the picture related to each feature, in order to have one page by feature with its location and its picture. With the button next to "image source", I tried to choose the "field type" that identify each feature and also to write concat(@project_folder, '/', "picture1.jpg")
in the expression, but neither of them worked...
Do you have an idea how to resolve this?
1 Answer 1
It appears you need to add the image by going to the Field Group Section and clicking Edit next to Include Body, and if the little grey tab above the layout shows you're in the Body: Group element, then you can access the fields of your Group layer for the image source field list, etc.
Keep in mind though it doesn't seem to work properly at first - at least for me I needed to test export a pdf before it seemed to actually place values in the text boxes/image in the image item, etc.
-
Thank you @she_weeds it works as a charme, even when adding an extra page to a report group.Helen Pater– Helen Pater2025年09月17日 15:09:37 +00:00Commented Sep 17 at 15:09
"picture1.jpg"
should either refer to a column (e.g."image"
) with double quotes, or a static string (like'picture1.jpg'
) with single quotes