Expand my Community achievements bar.

Is there a way to disable intructional text added to email?

Avatar

Level 1

I have a form that gets submitted as an attached XML file. Everything works fine but Acrobat also adds the following language to the body of the email that is generated:

"The attached file contains data that was entered into a form. It is not the form itself.

The recipient of this data file should save it locally with a unique name. Adobe Acrobat Professional 7 or later can process this data by importing it back into the blank form or creating a spreadsheet from several data files. See Help in Adobe Acrobat Professional 7 or later for more details."

My client doesn't need or want this in the email. Is there any way to prevent Acrobat from adding this text?

Thanks

David

8 Replies

Avatar

Level 10

Hi,

Instead of using the submit be email button, you can use a regular button and have something similar in the click event:

var vEmail = "someone@acompany.ie";     

var vSubject = "A9100 - Example of Email Button Script"

var vBody = "Hi\n\nPlease find attached the completed form.\n\nRegards,\n\nNiall"


event.target.submitForm({cURL:"mailto: "+ vEmail +"?subject=" + vSubject +"&body=" + vBody,cSubmitAs:"XML",cCharset:"utf-8"});

Note that the "\n" will insert a line break in the body of the text message. You can also specify the format of the returning form, by changing XML to PDF or XDP.

Hope that helps,

Niall

Avatar

Level 1

Thank you. That's helpful but I guess I'm still too XML ignorant to figure it out. If I insert a standard button the instance   looks like this:

<field name="Button1" y="190.925mm" x="35.632mm" w="28.575mm" h="6mm">

            <ui>

               <button highlight="inverted"/>

            </ui>

            <font typeface="Myriad Pro"/>

            <caption>

               <value>

                  <text>Button</text>

               </value>

               <para vAlign="middle" hAlign="center"/>

               <font typeface="Myriad Pro"/>

            </caption>

            <border hand="right">

               <?templateDesigner StyleID apbx2?>

               <edge stroke="raised" cap="butt"/>

               <fill>

                  <color value="212,208,200"/>

               </fill>

            </border>

            <bind match="none"/>

         </field>

Where is the click event in this code?

Avatar

Level 10

Hi,

I am out of the office now. But stay away from the XML Source tab!!!

Go back to the Design view and open the Object Library panel. This has a selection of standard objects (ready made) that you can drag onto your page. You are looking for the "Button".

You then need to open the Script Editor, it will appear at the top of your workspace. You can open it from the Window mwnu or Control+F5 (I think). If it is only one line deep, then drag the bottom bar to make it bigger/deeper.

Now select your button and go to the script editor. First there is a drop down list which allows you to select an event to put in script. Select click event. Copy and paste the script. Select Javascript as the lanuage and run at client (drop downs on right hand side). Then preview form.

You are able to do the scrikpting in the Design view and should only go into the XML source tab on rare occasions.

Hope that helps. Do a search on the forum for script editor and you wil gvet some more help.

Niall

Please contact me if you have any queries in relation to the above.

Regards,

Niall O'Donovan

Assure Health & Safety Consultants

086 2671985

Avatar

Level 1

Thank you very much. This might do the trick.

The only catch is that I now lose the pop-up window asking the viewer if they plan on using a desktop email application or an internet based email app. I thought that might be helpful for some users but perhaps I can do with out.

Thanks again for your time and expertise.

Avatar

Level 10

Okay,

Here is a sample with a messageBox to let the user know what will happen next.

You should also look at Paul Guerette's sample for different email options at Re: Variable E-mails in the e-mail button function

Hope that helps,

Niall

Avatar

Level 2

Hi Niall,

Hope all's well. Quick question if that's ok: I've been using Paul's suggestion you refer to, however the Acroform way doesn't really give the flexibility I'm after (choosing an XML datafile), so I've switched to trying to use JS on a click event, as you've specified with your attached file. However on testing, when pasting the 'submit' button into a new document (set as dynamic etc.), the button brings up the alert box but doesn't open the email client. I was wondering if you had any ideas?

Cheers

Avatar

Level 10

Hi,

Can you post a screenshot?

Generally when using a custom script solution, you would place the script in a regular button and NOT a submit button.

I have some email solutions here (which are developed versions of the earlier solution): http://assure.ly/eUR4wJ.

Hope that helps,

Niall

Avatar

Level 2

Hi Niall,

Sorry for the delayed response; thanks, your solutions were most helpful - I've cross-referenced yours to a couple of others and have fathomed something out for this one - user error [from myself] as usual! One thing designing a form for good usability, an entirely different thing to make it all work on-screen!

Thanks again.