Skip navigation

Email form as PDF, not XML

Jan 7, 2008 11:04 AM

  Latest reply: tdsilk, Aug 3, 2011 6:52 AM
Replies 1 2 3 Previous Next
  • Currently Being Moderated
    Sep 12, 2008 9:26 AM   in reply to (Paul_Urgero)
    I created a form that is digitally signed and then I added a submit button so the completed PDF form can be sent to a supervisor. It works fine except I cannot open the "pdf" before I send it. Although it looks like a PDF when you try to open before sending (which some people like to do before the send attachments) it doesn't find the file, but if you send it the person you sent it to can open the PDF just fine! I click on the properities of the "PDF" before sending it it only shows it as a label???? Is there a solution to for this problem or am I doing something wrong?
    Thanks!
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 12, 2008 11:45 AM   in reply to (Paul_Urgero)
    I think it is because you have the pdf opened, then click the email button which causes a dialog to come up (to do the email) then you ask for the original file to open again - but it is already opened.
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 22, 2008 9:40 PM   in reply to (Paul_Urgero)
    Hi!

    We have a form created in LiveCycle 8 (a survey), and need folks to fill in the responses and return it to us. We actually need the data, so XML return format should work fine. However, some of our respondents might not have an email client running (e.g., might be using hotmail or some such). Is there a way around this issue? If it involves 'HTTP Submit Button', could you spell out the instructions (or point me to them). As a disclaimer, I am a LiveCycle newbie, and don't know anything about php scripts... Thank you!
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 22, 2008 11:43 PM   in reply to (Paul_Urgero)
    Hi Sergey!

    When form is submitted by clicking submit button Adobe Reader usually popups a dialog where you can choose to use desktop email client or to save xml on a disk to be later sent by internet mail.

    I'm using usual Button object with Control type set to "Submit" and Submit to URL set to "mailto:some@address.com".

    If you have any questions please contact me.

    Regards, Andrey Erokhin
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 23, 2008 4:36 AM   in reply to (Paul_Urgero)
    1. Open your form in Designer.
    2. Add a Button object
    3. Go to Object panel ->Field
    4. From Control Type radio buttons select Submit
    5. Go To Submit Tab
    6. From Submit As dropdown list select PDF
    7. In a Submit to URL type mailto:
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 23, 2008 8:58 AM   in reply to (Paul_Urgero)
    Andrey,

    Thank you for your suggestion! Unfortunately, when I tried this out Acrobat Reader generated a message from MS Outlook which just said to set up the profile, and did not provide any other options (such as using webmail). Do you by any chance know how to set up the HTTP submission (including what to do server-side)? Thank you!

    Sergey
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 26, 2008 2:01 PM   in reply to (Paul_Urgero)
    Michael Hodgson - I tried your first solution and it was exactly what I was looking for. Thank you so much :)
     
    |
    Mark as:
  • Currently Being Moderated
    Sep 29, 2008 9:28 PM   in reply to (Paul_Urgero)
    Sergey,

    You can also try just to create button that would export xml data but you'll have to certify form and reader-enable it.
    You can find complete description of the process in Girish Bedekar's blog: http://eslifeline.wordpress.com/2008/06/04/importing-and-exporting-fo rm-data/

    There are several ways to process http submission but to choose one we should know what server Livecycle licenses you are planning to use?

    PS. Sergey, if you are from Russia you can call me - +7-495-228-0005.

    Andrey Erokhin.
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 23, 2008 9:33 AM   in reply to (Paul_Urgero)
    I followed the directions above to change the submit button so it will send in pdf format and it works when I try it with Adobe 7.0 Professional, but on the Advanced menu, there isn't "Enable Usage Rights in Adobe Reader" option any idea how I can get it to work in Reader? I've tried downloading "Extensions" but nothing seems to work.
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 23, 2008 10:33 AM   in reply to (Paul_Urgero)
    The Enable usage Rights in Acrobat was added in version 9.
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 29, 2008 8:54 AM   in reply to (Paul_Urgero)
    Thanks Paul. Is there another solution for my problem?
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 29, 2008 9:28 AM   in reply to (Paul_Urgero)
    Try this:

    Create a standard button and add this javascript code to the click event:

    var oDoc = event.target;
    oDoc.mailDoc({
    bUI: true,
    cTo: "emailaddress@gmail.com",
    cCC: "emailaddress@gmail.com",
    cSubject: "This is the subject",
    cMsg: "This is the body of the message"
    });
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 31, 2008 6:30 AM   in reply to (Paul_Urgero)
    Sorry Paul,

    I'm new at this. I have added a "button" and selected "regular" control type. But I don't know how or where to add the javascript because I can't seem to find the click event on button on the "XML source page" or am I even looking in the right place?
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 31, 2008 6:54 AM   in reply to (Paul_Urgero)
    Adding script is done through the script editor window. If the Script Editor is not displayed on the screen, select Window > Script Editor.

    I strongly discourage you from using the XML source page directly (especially if your new to XFA) as you can really mess up your forms. Its usually better to let the Designer tools modify the XML for you.
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 31, 2008 7:40 AM   in reply to (Paul_Urgero)
    Ensure the script editor is visible (as per Mike's post). Highlight the button. On th etop left you can choose the event where the code needs to execute. You want the click event. On the right side of th eeditor are two drop downs. One for language (choose javascript - it will be FormCalc otherwise) and leave the RunAt to be client. Now paste your code into the editor and preview the form. You are all set.
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 31, 2008 11:00 AM   in reply to (Paul_Urgero)
    Ok, that worked to send it from reader, but it didn't send the data. It said, "since changes to this form cannot be saved, your changes will not be sent" - any suggestions?
     
    |
    Mark as:
  • Currently Being Moderated
    Nov 15, 2008 10:11 AM   in reply to (Paul_Urgero)
    I have a form in which I dropped in a standard button and changed it so it will submit as a PDF attachment using "mailto". This works just fine, however the "Subject" of the email is jibberish. Is there a way to specify the subject when creating the submit button in this manner?

    Also, can you specify multiple email addresses?
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 2, 2008 1:54 PM   in reply to (Paul_Urgero)
    Hello... I was wondering if some here would know this... All I want to do is send the PDF to email... I figure that Id have to use a php script to relay the PDF as mailto: would try to open a program which they may not have. It needs to be the PDF not the XML of anything else as the receiver can't understand that... I thought this would be simple but I cant find anything really in Google searches... to much there to sift through lol.. anyways... I think It's go like this...

    Person opens form and fills it out
    They click HTTP Submit button
    PDF get sent to php
    Php then emails to receiver...

    Sounds simple... I do want anything else.. just the PDF relayed to the php script in stead of emailed through a mail client like outlook...

    :) thanks for the help

    Jeremy
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 3, 2008 5:37 AM   in reply to (Paul_Urgero)
    This is simple ....drop a button on the form. On the Object palette choose the submit radioButton (this makes it a submit button). A new submit tab will appear. Click on the submit tab. Here you can set the URL where th euser will submit to (your PHP program) as well as what you want to submit. Change the submit format to PDF and you are good to go.
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 3, 2008 5:57 PM   in reply to (Paul_Urgero)
    Ok so I know... what is getting sent to the php is a pdf? so I can use an emil script and set it as an attachment? (am at home and can't test it now sorry)

    if so... I know this script I made works...
    how do I "catch" the file here

    $filename = "example_011.pdf";

    ??? I guess thats the part I'm not getting now... thanks for the rest of the info.. :-)

    Jeremy

    require("../PHPMailer_v2.0.0/class.phpmailer.php");
    ////////////////////////////////
    /////////EMAIL AREA
    //////////////////////////////
    // create your pdf file. maybe give it a unique filename.
    $filename = "example_011.pdf";
    // use for Upload folder >>>>>>>>>>>>>>>>>
    $pdf->Output("/home/content/d/a/e/dowefrton/html/Csde/uploads/apps/" . $filename,"F");
    $pdf->Output($filename, "F");
    $mail = new PHPMailer();
    $mail->MsgHTML($body);
    $mail->AddAddress("absdfss3@roadsdfer.com", "John Doe");
    $mail->From = "*@sjrmc.org";
    $mail->FromName = 'SJRMC Personnel Department';
    $mail->Subject = 'Employment Application CC';
    $mail->Body = 'Thank you for submiting your application. REPLACE TEXT';

    if(!$mail->AddAttachment("example_011.pdf")) {
    echo "There was a problem attaching the pdf.";
    echo $mailer->ErrorInfo;
    }
    $dataResponse_1 = "passed";
    if(!$mail->Send()) {
    print("&response=error");
    } else {
    print("&response=passed");
    }

    ****************eidt***************
    also can I pass POST as well at the same time? then I can ??rename the fle?? I'd think and give a better response back to the cleint browser... thanks again
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 3, 2008 6:34 PM   in reply to (Paul_Urgero)
    Sorry I meant that with a POST I could send a better response like, use the first and last name in it... sounded like a question lol... I just don't know if both can be done...
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 4, 2008 11:20 AM   in reply to (Paul_Urgero)
    Ok I got it all but "catching" the file... tried saving in that script with no luck in the thought that I would just attach it like normal... any help there would be great...

    also on the POST... if I'm saving to the server I need to get the name out of the form to place it in the name of the file... I am a little at a lose on that part as well...

    thanks again for the help...

    Jeremy
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 6, 2008 6:21 PM   in reply to (Paul_Urgero)
    Ok so I am almost there... I can now catch the pdf and relay the pdf via the php script... one last thing is that I need to get the first and last name out of the pdf and pass it as well... that way I may insert it in the file name(alread have a time stamp on it)... and to also insert it in the response. any help here would be great ... I'm not sure how to "grab" that data and pass it in the post... js may-be? thank you...
    jeremyBass

    require("../PHPMailer_v2.0.0/class.phpmailer.php");
    ///////////////////////////////////////////////////
    //////////////////////////////////////////////////
    //// this is the catching of the PDF
    ////
    ///////////////////////////////////////////////////
    //////////////////////////////////////////////////

    $folder = "/home/content/*/*/*/*/html/Core/uploads/apps/";
    $fn = $folder . date("d-m-Y-His") . '.pdf';# make unique filename
    copy('php://input',$fn); # copy raw post data to file

    ///////////////////////////////////////////////////
    //////////////////////////////////////////////////

    ///////////////////////////////////////////////////
    //////////////////////////////////////////////////
    //// this is the Emailing of the PDF
    ////
    ///////////////////////////////////////////////////
    //////////////////////////////////////////////////

    // use for Upload folder >>>>>>>>>>>>>>>>>
    $mail = new PHPMailer();
    $mail->MsgHTML($body);
    $mail->AddAddress("*@*.net", "John Doe");
    $mail->From = "*@*.org";
    $mail->FromName = 'SJRMC Personnel Department';
    $mail->Subject = 'Employment Application CC';
    $mail->Body = 'Thank you for submiting your application. REPLACE TEXT';


    if(!$mail->AddAttachment($fn))
    {
    echo "There was a problem attaching the pdf.";
    echo $mailer->ErrorInfo;
    }
    $dataResponse_1 = "passed";
    if(!$mail->Send()) {
    print("&response=error");
    } else {
    print("
    Submitting successful

    Redirecting... one moment please");
    }
    ///////////////////////////////////////////////////
    //////////////////////////////////////////////////
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 12, 2008 2:04 PM   in reply to (Paul_Urgero)
    Any one know on this... Everything is working... I just need to get the first and last name out of the form... this way I can do something like this

    $userName = something here... ;

    $fn = $folder $userName. date("d-m-Y-His") . '.pdf'; #to make unique filename

    thanks again for the help
     
    |
    Mark as:
  • Currently Being Moderated
    Dec 16, 2008 4:43 PM   in reply to (Paul_Urgero)
    FYI on 51 of 63

    The java would not work at all for the cc:'d email address until "cCC" was changed to "cCc".

    Corrected text follows.

    var oDoc = event.target;
    oDoc.mailDoc({
    bUI: true,
    cTo: "emailaddress1@gmail.com",
    cCc: "emailaddress2@gmail.com",
    cSubject: "This is the subject",
    cMsg: "This is the body of the message"
    });

    After this change when opening the file you'd get an error "Operation could not be completed". It would still work and the form would be returned to both email addresses (actually distribution lists) after clicking "submit".

    As we needed to get rid of the error message. Changed it around to this and it seems to be working ok.

    var oDoc = event.target;
    oDoc.mailDoc({
    bUI: true,
    cTo: "emailaddress1@gmail.com.gov;emailaddress2@gmail.com",
    cSubject: "Move/Add/Change Form submission",
    cMsg: "The attached Move/Add/Change Form is submitted for your review."
    });

    thanks to all!

    Anyone tell me why the cc: version fails?
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 8, 2009 9:34 AM   in reply to (Paul_Urgero)
    Re: Leo Berliant - 4:36am Sep 23, 08 PST (#44 of 64)

    This worked great for me, but i am having an issue with the subject line. Is there a way to edit the subject line of the email using these steps? currently this works but the subject is a series of numbers i would like to be able to change this if possible.

    1. Open your form in Designer.
    2. Add a Button object
    3. Go to Object panel ->Field
    4. From Control Type radio buttons select Submit
    5. Go To Submit Tab
    6. From Submit As dropdown list select PDF
    7. In a Submit to URL type mailto:
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 8, 2009 10:48 AM   in reply to (Paul_Urgero)
    My guess is that you are testing this from preview and that group of numbers is the temp file name given to th ePDF. Once you save it as a real file and run it for real it will have the right file name.
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 9, 2009 4:21 AM   in reply to (Paul_Urgero)
    How do I rename the pdf when it is submitted. I did this and when sending the email, I notice that the subject are numbers and letters. Please let me know how to rename the subject.
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 12, 2009 11:05 AM   in reply to (Paul_Urgero)
    You can't ...it will take the name of the PDF when it is opened.
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 14, 2009 10:33 AM   in reply to (Paul_Urgero)
    I am having a problem getting my data emailed in PDF format. After reading some of the posts I attempted to drop in a regular button and choose the "submit" radio button. After choosing "submit as" PDF and typing in the email address I tested this in the "Preview PDF" option in LiveCycle Designer. Nothing happens. It works in XML. I need some assistance in figuring out what I am doing wrong.
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 14, 2009 12:52 PM   in reply to (Paul_Urgero)
    send your form to livecycle8@gmail.com and I will have a look
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 15, 2009 8:04 AM   in reply to (Paul_Urgero)
    Graham Houser Wrote:

    I have a form in which I dropped in a standard button and changed it so it will submit as a PDF attachment using "mailto". This works just fine, however the "Subject" of the email is jibberish. Is there a way to specify the subject when creating the submit button in this manner?

    Also, can you specify multiple email addresses?

    ----------------
    I had the same problem Graham and found the answer here: http://eslifeline.wordpress.com/2008/05/14/submit-pdf-by-email/

    Works perfectly!
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 22, 2009 1:47 PM   in reply to (Paul_Urgero)
    I am working in LiveCycle Designer ES and trying to submit a form as a PDF rather than XML. I have attempted to follow the directions posted here but I do not see the "submit as" field anywhere when I insert a button. I can insert a Standard button or an Email Submit Button. When I insert either type, there is no field where I can specify to submit the document as a PDF rather than XML. The Object Palette doesn't have this option.
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 23, 2009 4:58 AM   in reply to (Paul_Urgero)
    On the Object palette you must choose the radio button that makes it a submit button. Then a submit tab will appear where you will be able to set the options you want.
     
    |
    Mark as:
  • Currently Being Moderated
    Jan 23, 2009 6:07 AM   in reply to (Paul_Urgero)
    Ok, I managed to get that to work and chose the submit radio button which yielded the submit tab. I chose to have the form submitted as a PDF and put an email address in the URL field as "mailto:xxxxxx@princeton.edu" where xxxxxx is the actual email address. However, nothing happens when I click on the button.
     
    |
    Mark as:
  • Currently Being Moderated
    Aug 10, 2009 10:07 AM   in reply to (Jeremy_Bass)

    I'm trying to do the same thing.  However, I error out on the PHP page - INVALID SERVER RESPONSE.

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 11, 2009 6:58 AM   in reply to Hodmi

    Hi Hodmi,

    I have opposit problem, where I had LiveCycle Designer and every time I distribute my form and submit the form, it is attached as PDF.

    I want to submit the Form as XML, so I put a new button, and in the designed view -> submit as -> I selected  XML data.

    In the same time I selected Form Properties -> Defaults tab -> PDF render Format -> and I selected Dynamic XML Form.

     

    After I save the form and distributed it, I submitted it, but the form is attached as PDF not XML.

    I checked the Form properties and I found that is return back to PDF.

     

    So Can you help me with this, why I could not change the form properties to XML.

     

    Thanks   

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 3, 2009 11:36 AM   in reply to (Paul_Urgero)

    I have a PDF of an insurance application that I have added fields to in LiveCycle Designer ES. We want the user to fill out the form and then email it to us.

     

    When my test users open the PDF using only Reader, they have to go through all the steps to deactive PDF/A mode to see th fields needed to fill out.

     

    My first question - how do I make it so the document does not open in this mode and actually displays the fields we need them to fill out?

     

    Then my second issue is when the user tries to send me the form (after selecting to never show PDF/A mode!!!). I have tried implementing BOTH button types: Email Submit Button, which only sends me the XML data - NOT what I want.

     

    And I tried implementing the standard button type and including mailto:tpepe@usli.com, submit as: PDF, and nothing happens for my test users with Reader when they try clicking this - BUT IT WORKS FOR ME (I have Acrobat 9 Professional).

     

    I've read all of the posts within this thread and found nothing helpful.

     

    I even tried the javascript add to the click event on a regular button but CLICK is grayed out for me!

     

    Any help is greatly appreciated.

     

    Thank you!

    Attachments:
     
    |
    Mark as:
  • Currently Being Moderated
    Feb 3, 2010 9:15 PM   in reply to pguerett

    I've read through tons of posts and am simply trying to be able to provide a client with an interactive PDF that can be emailed once completed. I'm using Acrobat 7 Professional, added fields for data and a submit button which I have set using the combo box option and just a plain button. When I test in Reader I get the message "Operation not permitted." Can you explain, offer suggestions, etc.

     

    I am working on a Mac running OS 10.3.9 but do have access to a Windows machine with XP. Any suggestions?

     
    |
    Mark as:
  • Currently Being Moderated
    Feb 4, 2010 5:39 AM   in reply to CKVisiuals

    You need to Reader extend the form using ReaderExtensions so be able to email it back with Reader.

     

    Jasmin

     
    |
    Mark as:
Actions

More Like This

  • Retrieving data ...

Bookmarked By (0)