3 Replies Latest reply on Feb 4, 2013 12:00 PM by George_Johnson

    Forms: How do I let a user upload a picture from their computer into a form field?

    Andy Barba

      Hi There,

       

      This might not even be possible, but I would really appreciate some help.

       

      I am creating an invoice for graphic design services. It would be really helpful if each invoice could have a small screen shot (or "preview") image in a dedicated form field.

       

      1. I would like to create a field (something like a frame) where the image would appear.

      2. I would like the user to be able to click on a button that would search his/her computer for an image file

      3. I would like the field to be filled in with the chosen image. (Image would scale to fit inside the field).

       

      Does this make sense?

       

      If this is not possible or too complicated, how can I alternatively have the user click a button and attach an image file somehow from his/her computer?

       

      I am a beginner at javascript, sorry about that! I know this is a very ambitious project.

       

      Thank you!

        • 1. Re: Forms: How do I let a user upload a picture from their computer into a form field?
          George_Johnson MVP & Adobe Community Professional

          It's possible with a form created in Acrobat, but if it has to work with Reader, all Reader suers would have to use Reader 11 and the image would have to first be converted to a PDF, which can be done relatively easily nowdays. Post again if this will be feasible.

           

          It can also be done with an XFA form that you can create with LiveCycle Designer, which before Acrobat 11 cam with Acrobat Pro. If you upgraded from Acrobat 11 Pro from Acrobat 10 Pro, you should be eligible to receive a free copy. An XFA form can have an image field, which prompts the user to select an image of the following formats: JPEG, PNG, TIFF, GIF

           

          The alternative to including a visible image on the page is to instruct the user to use the "Attach a file as a comment" tool. This will be available to Reader users if the form is Reader-enabled and/or if they're using Reader 11.

           

          If you need access to the file if the form is returned to you, the latter approach is the easiest way to get at it.

          • 2. Re: Forms: How do I let a user upload a picture from their computer into a form field?
            Andy Barba Level 1

            Thank you George.

             

            After considering your options, the last one seems the most practical.

             

            How do you attach a file as a comment? It needs to be usable for Adobe Reader 10.

             

            Thank you!

            • 3. Re: Forms: How do I let a user upload a picture from their computer into a form field?
              George_Johnson MVP & Adobe Community Professional

              In Reader 10, the user would have to select: Comment > Annotations > Attach File (paperclip icon)

               

              Then click on a page and they will be prompted to select a file to attach. I usually include an area on a page that has the instructions and tells them to "Click here" when attaching the file.

               

              I believe it's the same for Reader 11, but in Reader 9 it's: Tools > Comment & Markup > Attach a File as a Comment