How can I have text from multiple fields on one layer, copy to one field on another layer?

A little help please as it's been years since I've done any coding of any sort.
So I have a 4 page document with various field types.  I have a document script that gets "TodaysDate" that works perfectly and a few other scripts as well.
So what I'm trying to do is find a work around for the following:
I have 3 fields - SURNAME, FIRSTNAME & dob.
And I want what is typed into these fields to populate into 1 field.  And according to this tutorial (http://acrobatusers.com/tutorials/how-save-pdf-acrobat-javascript) it's not exactly possible.  At least I think that's what it says.
However I'm hoping that maybe I could have a Submit button at the end of that document that when clicked would copy the text from those 3 fields (that I would have on 1 layer) into 1 field on a 2nd layer.  Is that even possible??
I'd also like to have the document Print, Save (using the text in the field on the 2nd layer as the file name), Email (using the text in the field on the 2nd layer as the subject line) and Export to a specific Excel spreadsheet. 
I don't want much do I?
I'm using Acrobat 9 Pro on a Windows PC but also have access to Acrobat 8 Professional.  And I'm going to want the form to run in Acrobat Reader X.
So far I have for the 3 fields into 1 on another layer:
function buttonClick(){
if(buttonClick==false)
event.value=this.getField("SURNAME"+"-"+"FIRSTNAME"+"-"+"dob").valueAsString;
But I have no idea how to call the event.value from 1 layer to another or if any of that code above would even work at all.
I have a script that I believe will work perfectly for the Save and Email function:
Using the “doc.submitForm()” function
// This is the form return e-mail. Its hardcoded
// so that the form is always returned to the same address
// Change address on your form
var cToAddr = "[email protected]";
// First, get the client CC e-mail address
var cCCAddr = this.getField("ClientEmail").value;
// Now get the beneficiary e-mail only if it is filled out
var cBenAddr = this.getField("BennyEmail").value;
if(cBenAddr != "") cCCAddr += ";" + cBenAddr;
// Set the subject and body text for the e-mail message
var cSubLine = "Form X-1 returned from client"; var cBody = "Thank you for submitting your form.\n" + "Save the mail attachment for your own records";
//** Send the form data as an XML attachment on an e-mail
// Build the e-mail URL
var cEmailURL = "mailto:[email protected]?cc=" + cCCAddr + "&subject=" + cSubLine + "&body=" + cBody;
this.submitForm({
            cURL: cEmailURL,
            cSubmitAs:"XML",
            cCharSet:"utf-8"
I'll work out the Export to Excel thing later as I've seen many tutorials on that.  But can I do the 3 fields to 1 thing at all?
Please Help!!!

Sorry Gilad.  I hope I'm not getting on your nerves (too much) but as I said it's been a while since I did any formal code. And I'm trying to do this code for a work document but I'm doing it in amongst so many other things I do for my job that it's difficult to get the time to concentrate for longer than 5 mins.
I didn't get a chance to try that code until just now.  I guess I asked again as I thought (from what I'd read) that it wouldn't be that simple.
So I've added that code and I get no errors.  But it doesn't appear to be doing anything either.  I've added the code like this in the Custom calculation script of a separate field I've called FileName.  And on the Button i'm using I've added:  buttonClick()
function buttonClick(){
if(buttonClick==false)
          event.value=this.getField("SURNAME").valueAsString + "-" + this.getField("FIRSTNAME").valueAsString + "-" + this.getField("dob").valueAsString;
So now I'm guessing that becasue i'm not getting an error or a result that I've screwed it up still.  Have I put the code in the correct area?  Have I assigned a the buttonClick() function correctly?

Similar Messages

  • How can I print texts from iPhone4 to Canon MX870

    How can I print texts from iPhone4 to Canon MX870

    The following gives instructions. http://support.apple.com/kb/HT4517
    Note that your carrier may not support it or may have added charges.
    To use this feature, enable Personal Hotspot on your cellular data plan. Contact your carrier for information and pricing.

  • How can i release text from a text box?

    How can I release text from a text box? I want the shape of the text box without the text in it.

    So all you need is to make a line around the text?
    For this you don't need to release the text box from the text. Just apply a stroke to it.

  • HOW CAN I IMPORT TEXT FROM MICROSOFT WORD TO THE WEB PAGE?

    HOW CAN I IMPORT TEXT FROM MICROSOFT WORD TO THE WEB PAGE?

    Another method is tosave your Word document as an a web page.  Then open the htm file, copy the text and paste into an HTML snippet on your web page.  Resize to show all the document and publish. It will retain the style, font and alignment of the original Word document.
    OT

  • HT201210 how can i retrieve texts from an earlier back up without changing all the other settings on my iphone?

    how can i retrieve texts from an earlier back up without changing all the other settings on my iphone?

    You can't. Restoring from a backup is all or none.
    You can use a utility such as this one to extract the messages from the backup on your computer but you can't re-transfer the messages to the Messages app on your iPhone.
    http://msb.macsupport-pr.com/

  • How do I select text from multiple pdf pages using Microsoft Document Imaging

    Hello.  I have scanned 3 pages and saved to pdf, now in Microsoft Document Imaging I can only select text from the first page and cannot select text from the other 2 pages.  Is there a way to select multiple pages?
    Thank you.
    Cat

    Why don't you ask in a MS forum? This forum is for an Adobe product and I have no idea why you are asking about Microsoft Document Imaging here.

  • How disable PDFEdit combines text from multiple Tj operators

    HI
    In http://help.adobe.com/livedocs/pdfl_sdk/9/PDFL_SDK9_HTMLHelp/API_References/Acrobat_API_Re ference/PDFEdit_Layer/PDEText.html mention that "PDFEdit combines text from multiple Tj operators into a single text run, when possible "
    how I can disable this feature
    I want disable this feature because  I write a program that process (encrypt) and copy every element recursively  , I used chain encryption algorithm that mean if one bit change  or shift all result will be wrong
    when I  encrypt, for example count 323 run in one textelement but after encryption and when I want decrypt in same textelement I just get 322 run, I think  this problem caused by PDFEdit combines text.
    thanks for your help

    Pdfedit can and often will write a completely different set of operators. It converts the operators to an object representation, then wites opererators for the objects. you cannot stop this, it is what it is supposed to do.

  • HT4994 How can i transfer texts from sim to new iphone 4s?

    Hi,
    I've just got a new iPhone 4s.When I ordered it with O2 the sales lady told me i could keep all my texts from old samsung phone by transferring them onto the new sim and then from that onto the phone. I've got as far as putting the new sim in the phone but can't find how to get the texts from the sim onto the new phone.
    Can anyone help please?
    Many thanks.

    I don' t want them to get away with crap selling and now even more appalling customer service. And i don't want to lose my texts which are now on a microsim that won't tranfer to the iphone. I just want someone to say-yes we cocked and now we're going to fix this ( different phone, money off etc) but they are telling me there's nothing i can do except drive a 50mile round trip to one of their shops (but they won't pay for petrol). I'am about to explode!!!!

  • How can I transfer music from my new Macbook Air to my old one

    I can't transfer music from my new Macbook Air to the new one. I have,however, transfered music from my old one to the new one. What am I doing wrong?

    http://support.apple.com/kb/HT4527

  • How can I take text from a webpage that is in multiple rows and move it into a single row in Excel?

    I need help figuring out how to take data from internet pages and enter it into one single row in an excel, or numbers if that is the easier way to go.  I was also told access might be good to use.  Basically I am going to chamber of commerce page and wanting to extract the member listing and enter in a database in a single line.  The  data is in different numbers of lines as you will see below (info edited to take out personal info). So I want to take the  name of business, business owner, address, city, state, zip, and phone and put it into one line on a spreadsheet.  I want to do this many times over. I think there is a way to do it through apple script and automator, but I have not been successful after 2 weeks of trying and searching.  I have over 800 listings and I surely don't want to go through and do them one at a time.  Any suggestions?
    Data from website:
    Westrock Coffee
    Mr.
    Collins Industrial Place
    North Little Rock, AR 72113
    Phone:
    Send Email
    Member Since: 2011
    Sweet Creations by DJ
    Ms. J
    allace Bridge Road
    Perryville, AR 72126
    Phone:
    Fax:
    Send Email
    Member Since: 2013
    See Also Woman Owned and/or CEO
    Premium Refreshment Service
    Mr. E
    est Bethany Road
    North , AR 72117
    I want it to look like this
    Company name, owner name, address, city, state, zip, phone
    How can I get the extra data out of the way and remove the format so that it will go into excel?  Thanks for any help you can provide.  I am not to savvy with code, but I got a friend who is an IT guy that can help.  Thanks again

    So, basically, create 800 individual entries, each one containing everything from business name through the phone (not fax) number, add some commas and spaces to entries, and then put each entry on a separate line?
    1. Go to website page such as this one-- http://www.littlerockchamber.com/CWT/External/WCPages/WCDirectory/Directory.aspx ?ACTION=newmembers --which seems formatwise very close to what you're trying to scrape.
    2. Cmd-A to select all. Cmd-C to copy it to clipboard.
    3. Open freeware TextWrangler. Cmd-V to paste info from clipboard into a blank TW document.
    4. Remove lines from top and bottom so that only membership list remains.
    5. Process lines to remove everything from "Fax" line through "See Also" line. Only business name through phone number will remain in the file.
    --A. TW > Text > Process Lines containing . . .
    -----(check "Delete matched lines"; uncheck all others)
    -----Enter "Send Email" in the search box.
    -----Click Process.
    --B. Repeat 5A for other lines to be removed
    ------Member Since
    ------See Also
    ------Fax
    6. Insert markers to separate entries:
    TW: Search > Find . . .
    ------(check "Wrap around" and "Grep")
    ------in Find box: \r\r\r\r
    ------in replace box: \r***
    ------Click Replace All
    7. Remove remaining blank lines:
    TW: Search > Find . . .
    ------(check "Wrap around" and "Grep")
    ------in Find box: \r\r
    ------in replace box: \r
    ------Click Replace All
    8. Add comma and space at end of each line:
    TW: Search > Find . . .
    ------(check "Wrap around" and "Grep")
    ------in Find box: $
    ------in replace box: ,  (comma space)
    ------Click Replace All
    9. Remove all returns:
    TW: Search > Find . . .
    ------(check "Wrap around" and "Grep")
    ------in Find box: \r
    ------in replace box: (leave blank)
    ------Click Replace All
    10. Insert returns in place of markers:
    TW: Search > Find . . .
    ------(check "Wrap around" and "Grep")
    ------in Find box: \*\*\*,  (backslash asterisk backslash asterisk backslash asterisk comma space)
    ------in replace box: \r
    ------Click Replace All
    11. Remove trailing comma and blank on each line:
    TW: Search > Find . . .
    ------(check "Wrap around" and "Grep")
    ------in Find box: , $ (comma space dollar sign)
    ------in replace box: (leave blank)
    ------Click Replace All
    Import this text file into Excel or Numbers.

  • How can I take data from multiple pages documents and put them into a numbers table?

    I produce invoices in pages, with dates, invoice numbers, references and amounts due. I want to take all this data from multiple documents and transfeer it to a single numbers table. Is this possible and if so, how do I do it. I know I can do it the other way round with mail merge but I can't figure out how to do it this way round?
    Thanks,
    Keith

    The data is spread throughout a pages document in specific areas here's a copy of an invoice for you to have a look at.

  • How can i print text contain multiple language

    hi all,
    i have swing application with JTextPane contains multiple data (kannada and English)
    i used to the follwoing code to print contatent of jtextPane and in this code i seted
    font Kedage(for kannada)
    if did not set to kannada font the kannada test is printing squre box
    if i set english font than kannada the english font is squre box,
    here how can i identify the the character is kannada and english
    help me to solve this problem or suggest me any other way to print multiple language
    text in JTextPane.
         public void printMeetingDetails(String meetingDate){
                   PrintJob pjob = getToolkit().getPrintJob(new JFrame(), "Meeting Details", new Properties());
                    if (pjob != null) {
                      Graphics pg = pjob.getGraphics();
                      if (pg != null) {
                        String s1 = taMeetingDetails.getText();
                        s1 = s1 + "\n Resolution :";
                        //String s2 = "\n This is the second paragraph for printing after the sample java code.";
                        String s2 = "\t"+taResolution.getText();
                        printLongString (pjob, pg, s1,s2);
                        pg.dispose();
                      pjob.end();
              private int margin = 72;
                // Print string to graphics via printjob
                // Does not deal with word wrap or tabs
                private void printLongString (PrintJob pjob, Graphics pg, String strEng,String strKan) {
                  int pageNum = 1;
                  int linesForThisPage = 0;
                  int linesForThisJob = 0;
                  // Note: String is immutable so won't change while printing.
                  if (!(pg instanceof PrintGraphics)) {
                    throw new IllegalArgumentException ("Graphics context not PrintGraphics");
                  StringReader srEng = new StringReader (strEng);
                  StringReader srKan = new StringReader (strKan);
                  LineNumberReader lnrEng = new LineNumberReader (srEng);
                  LineNumberReader lnrKan = new LineNumberReader (srKan);
                  String nextLine;
                  int pageHeight = pjob.getPageDimension().height - margin;
                // Font helv = new Font("Kedage", Font.PLAIN, 12);
                  Font helv = new Font("Kedage", Font.PLAIN, 12);
                  //have to set the font to get any output
                  pg.setFont (helv);
                  FontMetrics fm = pg.getFontMetrics(helv);
                  int fontHeight = fm.getHeight();
                  int fontDescent = fm.getDescent();
                  int curHeight = margin;
                  try {
                    do {
                      nextLine = lnrEng.readLine();
                      if (nextLine != null) {        
                        if ((curHeight + fontHeight) > pageHeight) {
                          // New Page
                          System.out.println ("" + linesForThisPage + " lines printed for page " + pageNum);
                          if (linesForThisPage == 0) {
                             System.out.println ("Font is too big for pages of this size; aborting...");
                             break;
                          pageNum++;
                          linesForThisPage = 0;
                          pg.dispose();
                          pg = pjob.getGraphics();
                          if (pg != null) {
                            pg.setFont (helv);
                          curHeight = 0;
                        curHeight += fontHeight;
                        if (pg != null) {
                          pg.drawString (nextLine, margin, curHeight - fontDescent);
                          linesForThisPage++;
                          linesForThisJob++;
                        } else {
                          System.out.println ("pg null");
                    } while (nextLine != null);
                    Font fMyFont = new Font("Kedage", Font.PLAIN, 12); //for kannada
                    //have to set the font to get any output
                    pg.setFont (fMyFont);
                    fm = pg.getFontMetrics(fMyFont);
                    fontHeight = fm.getHeight();
                    fontDescent = fm.getDescent();
                    curHeight += fontHeight;
                    do {
                      nextLine = lnrKan.readLine();
                      if (nextLine != null) {        
                        if ((curHeight + fontHeight) > pageHeight) {
                          // New Page
                          System.out.println ("" + linesForThisPage + " lines printed for page " + pageNum);
                          if (linesForThisPage == 0) {
                             System.out.println ("Font is too big for pages of this size; aborting...");
                             break;
                          pageNum++;
                          linesForThisPage = 0;
                          pg.dispose();
                          pg = pjob.getGraphics();
                          if (pg != null) {
                            pg.setFont (fMyFont);
                          curHeight = 0;
                        curHeight += fontHeight;
                        if (pg != null) {
                          pg.drawString (nextLine, margin, curHeight - fontDescent);
                          linesForThisPage++;
                          linesForThisJob++;
                        } else {
                          System.out.println ("pg null");
                    } while (nextLine != null);
                  } catch (EOFException eof) {
                    // Fine, ignore
                  } catch (Throwable t) { // Anything else
                    t.printStackTrace();
                }thanks
    daya

    hi all,
    i have swing application with JTextPane contains multiple data (kannada and English)
    i used to the follwoing code to print contatent of jtextPane and in this code i seted
    font Kedage(for kannada)
    if did not set kannada font then kannada text is not printing porperly(printg squre box)
    if i set kannada font then english font is squre box,
    here how can i identify the the character is kannada and english characater
    help me to solve this problem or suggest me any other way to print content of jtextpane which is in multiple language text.
    public void printMeetingDetails(String meetingDate){
                   PrintJob pjob = getToolkit().getPrintJob(new JFrame(), "Meeting Details", new Properties());
                    if (pjob != null) {
                      Graphics pg = pjob.getGraphics();
                      if (pg != null) {
                        String s1 = taMeetingDetails.getText();
                        s1 = s1 + "\n Resolution :";
                        //String s2 = "\n This is the second paragraph for printing after the sample java code.";
                        String s2 = "\t"+taResolution.getText();
                        printLongString (pjob, pg, s1,s2);
                        pg.dispose();
                      pjob.end();
              private int margin = 72;
                // Print string to graphics via printjob
                // Does not deal with word wrap or tabs
                private void printLongString (PrintJob pjob, Graphics pg, String strEng,String strKan) {
                  int pageNum = 1;
                  int linesForThisPage = 0;
                  int linesForThisJob = 0;
                  // Note: String is immutable so won't change while printing.
                  if (!(pg instanceof PrintGraphics)) {
                    throw new IllegalArgumentException ("Graphics context not PrintGraphics");
                  StringReader srEng = new StringReader (strEng);
                  StringReader srKan = new StringReader (strKan);
                  LineNumberReader lnrEng = new LineNumberReader (srEng);
                  LineNumberReader lnrKan = new LineNumberReader (srKan);
                  String nextLine;
                  int pageHeight = pjob.getPageDimension().height - margin;
                // Font helv = new Font("Kedage", Font.PLAIN, 12);
                  Font helv = new Font("Kedage", Font.PLAIN, 12);
                  //have to set the font to get any output
                  pg.setFont (helv);
                  FontMetrics fm = pg.getFontMetrics(helv);
                  int fontHeight = fm.getHeight();
                  int fontDescent = fm.getDescent();
                  int curHeight = margin;
                  try {
                    do {
                      nextLine = lnrEng.readLine();
                      if (nextLine != null) {        
                        if ((curHeight + fontHeight) > pageHeight) {
                          // New Page
                          System.out.println ("" + linesForThisPage + " lines printed for page " + pageNum);
                          if (linesForThisPage == 0) {
                             System.out.println ("Font is too big for pages of this size; aborting...");
                             break;
                          pageNum++;
                          linesForThisPage = 0;
                          pg.dispose();
                          pg = pjob.getGraphics();
                          if (pg != null) {
                            pg.setFont (helv);
                          curHeight = 0;
                        curHeight += fontHeight;
                        if (pg != null) {
                          pg.drawString (nextLine, margin, curHeight - fontDescent);
                          linesForThisPage++;
                          linesForThisJob++;
                        } else {
                          System.out.println ("pg null");
                    } while (nextLine != null);thanks
    daya

  • How can i group text from my iphone 4s

    I'm in a band & scheduling practices gets kinda tricky.I just got an iPhone 4s & I can't figure out how to send group texts. I have the group set up but I have to select each person seperately from within the group. I had a Blackberry Curve (which I hated!) that did this easily. How can I do this with my iPhone (which I love!)?

    Or you can contact your operator and check what they can do for you , there is a service in Egypt called group SMS which you can have from 0 to 99 group and every group cost you 1 MSG

  • How can I import text from Word including paragraph indents?

    I'm using Captivate 7.
    I need to import text from a series of documents written in Microsoft Word.
    When I copy and paste most of the formatting is retained. Bold, italics and underline import perfectly but I lose the indented paragraphs. They all become left aligned.
    Is there a way to import the indented first lines in the paragraphs?
    Thanks in advance.

    Lilybiri, sorry it took me so long to get back to you. Life sometimes interferes with living.
    Thanks for sharing your opinions. Your deep and penetrating insights have changed my life forever. As in: "...that people expect ..." Gee; I've pondered that for years. Now that you've opened my eyes to "what people expect" I can let that go and concentrate on something else. Like, is cheese REALLY binding?
    With your helpful and concerned attitude I'm sure you'll be glad to know that my problem has been solved. Not by anything from Adobe; the company or the forum, but by simply finding another program that works as it should.
    By the way, I marked my own answer correct as it was clear that there is no answer and I just wanted to close the thread. Actually, after I reread what I said,  I realized my answer IS correct. So, I'll stand by it.
    Thanks again, it's been interesting.
    So long Lilybiri, and good-bye Adobe Captivate.

  • How can I get file from multiple instance using file adapter

    Hi.
    Our system(PI7.1) have three application instances running with each physical servers.
    We use sender file adapter.
    The file data is sent to one of the servers.
    Now, how can I get the file using three file adater?
    Should I put the file "sapmnt(\usr\sap)" .
    Or are there another solution?
    regards,

    Hi Ashutosh
    You will have to use sapcar.zip which contains the utility Sapcar.exe utility for unzipping the files from SAP compressed files. (*.car file)
    Regards
    Gaurav
    PS: Reward points if solved

Maybe you are looking for