Tap Forms – Organizer Database App for Mac, iPhone, and iPad › Forums › Using Tap Forms › File Attachment preview for PDF on the form body
May 23, 2023 at 9:25 AM #49461
I have a form with a field of type File Attachment that I uses to store a single PDF file. As the PDF content is the most important piece of information for the given form (together with two other 2 or 3 fields that acts as metadata) I would like to be able to preview immediately the content of the PDF, as long as i change record, instead of clicking on the “preview icon”.
When I change records as I need to consult and compare many of them in sequence, I always have to click on the preview button and than tap on Close to dismiss the preview. Having a preview in the form body will improve the User Experience of my use case a lot.
I imagine other use cases, for example a field type that show a interactive map, embedding a WebView for example.
Is there a way to configure a form to achieve that behaviour?
thank youMay 23, 2023 at 9:50 AM #49462
Just to add an extra clarification, I would like that File Attachment types (or a new type of field) would work as Container field in FileMaker, that in case of well know types are automatically previewed with the extra option of interaction (for example scrolling the pages of the PDF in the preview).
iOS/iPadOS SDK (UIKit) provides a native view (WKWebView) that is able to preview many common file types and can be embedded in the parent UIView/UIStackViewMay 24, 2023 at 10:35 PM #49473
Actually, the Photo field in Tap Forms 5 can do this. It will display the first page as a preview and then when you click on the PDF in the Photo field, Tap Forms will display the media browser window which lets you navigate the different pages of the PDF file.
BrendanMay 25, 2023 at 8:02 AM #49475
thank you Brendan, I have tried but it seems it doesn’t work on iOS/iPad: for the Photo type I can only choose Images from the Photo Gallery. I guess you were referring to the macOS version of tap forms where it actually works, however I can only preview the first page and not scroll into the document.
So I guess there is no way to achieve this on the iPad (that was my need)
May 25, 2023 at 10:49 AM #49478
- This reply was modified 4 months ago by Antonio Calanducci.
Ah my apologies, I missed that you were referring to the iOS version.
I’m familiar with the WKWebView. The File Attachment field on iOS uses the QuickLook functionality to display the contents of a file that you tap on. So you should be able to see all pages. Just not a preview in the list.
Perhaps in a future version of Tap Forms I’ll add that ability. I’m about to embark on a big change to the iOS version once I am finished with all the improvements I’m making to the Mac version.
BrendanSeptember 1, 2023 at 4:17 AM #49801
I have tried both the iPadOS and macOS version and I could not find a comfortable way to switch between documents and read immediately the attached PDF. So I guess there are currently no option to achieve this, but please let me know if I am wrong.
I think PDFs need their own field type to be handled properly as they are super important. Recently I have tried DevonThink 3 and I would love to have a similar browsing experience in tap forms. Hopefully you could take this into account for future versions.
Another option would be to implement a WebView field type (as FileMaker does) that would allow to embed for example a JS PDF viewer or any JS based viewer (excel, word, etc) with the effect to be able to browse/read document inline.
Thank youSeptember 1, 2023 at 1:30 PM #49805
Did you try the Photo field with your PDF file? When you use that you can view the contents of the PDF file and navigate through all of its pages.
BrendanSeptember 1, 2023 at 2:24 PM #49806
yes I did, but I need to click and a new window will open up with a media browser. I was expecting instead to browse the pdf in the form itself, so that I can switch between records and preview instantaneously the attached PDF.
Is there any way to achieve this on macOS or on iPadOS? thanks
September 1, 2023 at 10:22 PM #49808
- This reply was modified 3 weeks, 2 days ago by Antonio Calanducci.
Ah I see. So you want to view a record and just see the PDF file inline on the record details view without having to click. Only the media viewer window on macOS can do this and on iOS you need to use a File Attachment field instead to view PDF files and their multiple pages.September 2, 2023 at 12:04 AM #49809
Ah I see. So you want to view a record and just see the PDF file inline on the record details view without having to click.
Only the media viewer window on macOS can do this and on iOS you need to use a File Attachment field instead to view PDF files and their multiple pages.
I am trying on macOS and I am not able to achieve this: I still need to click on the photo thumbnail that previews the pdf and this open a separate media browser window. Then, if I switch to another record, and click again on the pdf preview again, it will open up a new media browser window, and so on, with the result of having many media browser windows as many records I consulted.
What am I doing wrong? maybe there is some setting to embed the media browser inline into the record detail window?September 2, 2023 at 8:59 PM #49810
You’re not doing anything wrong. That’s how it works. Sometimes people want to view different photos and PDFs at the same time instead of only one at a time. So that’s why a new window is opened for each record.
In a future version of Tap Forms I’ll see about improving that in some way. You can add a Photo field to a custom layout and size the file large. But it will only show the first page of the PDF until you open the media browser window. There does seem to be a small bug with the custom layout though. If you add the PDF file from the custom layout, it will not display all the pages when you open the media browser. But if you add them via the Default Layout, then you can open it up on the custom layout too to view all the pages.
You must be logged in to reply to this topic.