I am attempting to create a work-around that displays PDF and image files in a Gallery of an SP List custom form app.
I've got it to this -
The Gallery (on the right) has 'TTG Medical History Template' in its Items property.
The Gallery Image control has the following in it's Items property.
"https://------------.sharepoint.com/_layouts/15/getpreview.ashx?path=" & First(LookUp([@'History Template'], FullName = DataCardValue4.Text).Attachments).AbsoluteUri

I can get the document to display in the Image control, however it shows the same image as many times as there are items on the SP List (three in this case), rather than the single page that it is (or the multiple different pages of the PDF or Image).
Why does the Image control show the same image multiple times even if the original document may only be a single page document, or shows the same image four times when the document has eight different pages?