Page 1 of 1
Signature Pad
Posted: Tue May 22, 2018 11:10 am
by mcorbo
Just found the signature pad widget. We are looking to create an application where a driver can sign a Bill of Lading on a tablet. The Bill of Lading would already exist in a PDF file. Can I display the PDf File and then add a Signture pad in the appropriate place so it looks to them like they are signing the actual document?
Re: Signature Pad
Posted: Mon Jun 04, 2018 1:09 pm
by Scott Klement
As far as I know, there's no way to embed a PDF document in a mobile web browser... Unless there are some special plugins available or something like that? I guess that's possible, but it's new to me.
Assuming I'm right, your PDF will open in a separate window from the Profound UI app -- and therefore, there's really nothing we can do to interact with it.
If you wanted to convert your Bill of Lading to a format like JPG, PNG, etc, then you may be able to make it work by setting it as a background image or similar, and overlaying the signature pad at the right spot.
Re: Signature Pad
Posted: Mon Jun 04, 2018 1:16 pm
by mcorbo
Thanks Scott
I had already determined since posting this question that I would need to convert to jpg etc to make this work and has found this link on your site
https://www.scottklement.com/imagemagick/ but can not seem to get it to work. The only other native option I could find for the i was iForms which is very cost prohibitive just to perform this single conversion function.
It does work nicely once I have the pdf in jpg format.
Re: Signature Pad
Posted: Mon Jun 04, 2018 1:18 pm
by Alex
You may be able to use an IFrame widget to display a PDF. I am not sure if this will work in all browsers.
Then, if you are able to make it work with an IFrame, you could put the Signature Pad widget on top of the IFrame. You will have to make sure that the Signature Pad has a higher "z index" than the IFrame widget, so that it actually appears on top.
Re: Signature Pad
Posted: Mon Jun 04, 2018 1:44 pm
by Scott Klement
iframe is a good idea, but will only work if the browser can display a PDF inline. If it opens the PDF in a separate window, then it won't work. This should be easy to test and see if it works for you.
Re: Signature Pad
Posted: Mon Jun 04, 2018 1:46 pm
by Scott Klement
As for Imagemagick, I don't remember it supporting PDF format? I could be wrong, though, as it has been ages since I looked into it.
I believe GhostScript supports PDF, so that might be a possibility. I also haven't looked at that in many years, but back in the day, it worked with simple PDFs. When they got complex, I had to use Adobe Reader. (Adobe Reader doesn't run on IBM i)
Re: Signature Pad
Posted: Mon Jun 04, 2018 1:56 pm
by dcutter
I've used an HTML container widget with an object tag in the HTML to display PDF documents on a screen with additional information. It seems to work ok on an iPad also.
Re: Signature Pad
Posted: Mon Jun 04, 2018 3:39 pm
by mcorbo
I tried the PDF in an html container and it opened a pdf viewer in the html container. I finally got ghostscript working for the pfd to jpg conversion and will be using the jpg in the html container.