Hello,
Can you suggest best way (different ways) to handle following situation.
I'm creating reporting system by which will eventually create report for made operation. The report contais front page, summary table in second page (might flow to next pages as well) and then detailed report rows with measured values etc in _table_. In addition, the executed checks might contain one picture or more. Some checks does not contain pictures at all.
In report, the picture attachments are all in the end of document (last pages are dedicated for attachments). Each signle attachment piccture will cover whole A4 page.
This leed me as a developer in situation where I should be able to reference future pages before hand there is page numbers available. How this problem could be solved?
Stil short example: on the page 4 is detailed table of made check. That check will have one picture as attachment and the picture will be shown in page e.g. 10. But writing the detailed row the picture page number is not known yet. In the detailed check row there should be stated "Please see picture attachment on page 10". So one might create the same pdf document twice and then know the page 10 in second iteration loop, but that does not sound very sophisticated solution for this problem. How about templates, composition fields, etc.?
Edit in addition to previous: When the code have passed over page 10 and really added the picture attachment, it should be able to "go back" to page 4 and update the reference field to be really page 10. Could this functionality be also created by some textual placeholder like "PictureXYZ_placeholder". Search that string and replace it with correct reference string?