23 Replies Latest reply on Jun 16, 2011 9:02 PM by John Hawkinson

    InDesign CS5 mailmerge into different text boxes

    DCordova Level 1

      I have to create a file for tabs using a mailmerge for the list of tabs. What I am attempting trying to do (attempted but failed miserabley) is setting up 5 master pages (one for each bank) and running a mail merge. What has happened is that it will give me 5 banks of the same tab. For instance, "Executive Summary" five times, then "Introduction" five times. I usually create one master and manually move them but this particular project has over 500 tabs using drawing numbers and I am not feeling that generous and I am slightly dislexic.

       

      Is there an easy way to do this without having to do one master and then manually go through each page to setup the bank placement? I searched the forums but I can only find references to tab deliminators.

       

      The page consists of two text boxes--the tab title and the actual tab which say the same thing.

       

      Thanks in advance.


      Dawn

        • 1. Re: InDesign CS5 mailmerge into different text boxes
          Peter Spier Most Valuable Participant (Moderator)

          You should show us some sort of mock-up of what you want to do.

           

          Do you mean you are doing a Data Merge (you need the correct term to use thye help system effectively)? It sounds like you might be trying to do a multiple records per page merge with multiple fields on your template. That doesn't work. For multiple records per page you need to have exactly one set of placeholders. It would help, too, to know what the data file looks like.

          • 2. Re: InDesign CS5 mailmerge into different text boxes
            DCordova Level 1

            1 A

            Tab Title A

             

            2 B

            Tab Title B

             

            3 C

            Tab Title C

             

            Tab Title D

            4 D

             

            Tab Title E

            5 E

             

            Please let me know if that makes sense. Each page has two text boxes but they say the same thing. I get the list in word but can throw it into anything in any order. Xcel, txt, etc.

            • 3. Re: InDesign CS5 mailmerge into different text boxes
              Peter Spier Most Valuable Participant (Moderator)

              How is thius arranged on a page? You said two text frames, but both say the same thing, and that is not clear. Do you mean there are two sets of data on each page, and both are the same? It would really help if you mocked up an actual page, then do a screen capture. You can embed the capture in a post using the camera icon on the web page:

              CameraIcon.png

              • 5. Re: InDesign CS5 mailmerge into different text boxes
                Peter Spier Most Valuable Participant (Moderator)

                This is tricky to automate.It might be scriptable, but I don't write scripts, so here's how I think I would do it without a script, using Data Merge.

                 

                First, this is a single record per page merge, but you need two fields in each record, both of which have the same text. The trick is to add a series of tab characters to before the text in the second field that will become the tabs. Set up just two text frames on the page, one in the center, and a long one running vertically down the edge that will become the tabs. Create a paragraph style for each type of frame and apply it, and for the tabs frame set tab stops as part of the style.

                 

                The problem here is that it will take as long, I suspect, to create the data file as it would to do the whole thing manually, but maybe someone with more Excel experience can tell uus how to cleverly automate adding a progression of tabs in front of the entry, and then cyle through. Perhaps a sequence of concatenation functions that repeats down the column. You'd also, I think, have to use a placeholder character of some sort for the tabs, then run Find/Change after the merge to replace them and get things positioned correctly. Another option would be to use 6 fields, and put the tab text in the correct field for each tab, leaving the other 4 blank (the first field contains the text for the frame in the center of the page).

                1 person found this helpful
                • 6. Re: InDesign CS5 mailmerge into different text boxes
                  DCordova Level 1

                  This is going to be tricky! I appreciate your help and am going to try this. I will post as soon as I can find a solution. I am hoping to find some

                  thing that works in case this happens again.

                  • 7. Re: InDesign CS5 mailmerge into different text boxes
                    Peter Spier Most Valuable Participant (Moderator)

                    I've been thinking about this some more, and I think you should head over to the scripting forum (http://forums.adobe.com/community/indesign/indesign_scripting). I have a feeling it would be fairly easy to add tabs to the text after the merge instead of trying to get them in before hand.

                    • 8. Re: InDesign CS5 mailmerge into different text boxes
                      peter minneapolis Level 4

                      DCordova wrote:

                       

                      Picture4.jpgPicture3.jpg

                      Perhaps my not being a print-production person is making me feel lost here. I'm trying to understand what you're trying to do.

                       

                      I don't see any numbers, and I don't understand "drawing numbers." What am I missing?

                       

                      I also don't understand "banks." Do you mean that there are five positions along the side, like file tabs? Your example only has four possible tab positions.

                       

                      Are you trying to describe 100 sets of five tabs per set, each tab with a different text like Table of Contents, Chapter 1, Chapter 2, Chapter 3, Index? Or, are there 500 different texts, like Table of Contents, Chapter 1, Chapter 2, Chapter 3, Chapter 4 in the first set of five tabs, then Chapter 6 through 9 in the second set of five, etc., all the way down to ...chapter 498, Index?

                       

                      Are you trying to describe some way to print "multiple-up" sets per page and cut them into stacks the size of a single page?

                       

                      As far as repeating the main title text on the side, you can create a running header variable, in a rotated text frame on the master page, to capture the main text. You can create the main document pages with data merge, though a merge can only have one master page.

                       

                      As far as data merge, if you have 500 items in a suitable file for the data source, data-merge can create 500 pages with main text from that file, and use a master page that captures the side text in its running header. If the running headers need to be in one of five tab positions at the side, you'll need one master page for each running header position, to capture each page's main text, if all the main texts use the same paragraph style.

                       

                      After the merge with a single master page, you'll need to assign every n-th main-text page to the appropriate master page with a tab in the right position. The problem of placing each main text into the appropriate side running header position could be solved by a script that replaces the master page used for every n-th main text page with a master page whose side text frame is in the n-th position. Another approach would be to create one master page with five side tab text frames, each using a different running-header text variable that captures one of five paragraph styles, and using a script to apply one of the five paragraph styles to the main text on each document page. These are concepts that you'll need help with if you want to implement.

                       

                      HTH

                       

                      Regards,

                       

                      Peter

                      _______________________

                      Peter Gold

                      KnowHow ProServices

                      • 9. Re: InDesign CS5 mailmerge into different text boxes
                        John Hawkinson Level 5

                        I feel like you guys are overthinking this.

                        There are 5 seperate kinds of "tabs", right?

                        Just do 5 seperate merges of 100 records each and you're done.

                        Duplicate the data in the spreadsheet that generates the merge data file, it's trivial to do there.

                         

                        This is made trebly confusing by the word "tab," which I think in Dawn's usage is "thing that sticks out of the page" and other times might be the alignment character.

                        • 10. Re: InDesign CS5 mailmerge into different text boxes
                          DCordova Level 1

                          That's exactly what I was going to try. The tabs are not numbered. When I refer to "tabs" I am referring to the portion that sticks out of the page. I make tabs for multiple reports and different banks (3-bank; 5--bank, etc. depending on client requests). This one in particular is referring to engineering drawings that are numbered like P2K39036OLE17 or something totally incoherent and a pain to retype. I am going to try the double the information for placement. One tab page has two text boxes that say the same thing. Each page is a different bank. I made 5 master pages for each of the 5 banks which worked except it made 5 pages saying the same thing and the next set of five pages saying the same thing. I will tackle this afternoon again and see what I can come up with.

                          • 11. Re: InDesign CS5 mailmerge into different text boxes
                            John Hawkinson Level 5

                            When I say five seperate merges, I mean five seperate documents. Don't combine all 5 together. Isn't there a reason that's hard? It shouldn't be much extra work.

                            • 12. Re: InDesign CS5 mailmerge into different text boxes
                              Peter Spier Most Valuable Participant (Moderator)

                              Pre-cut tabs come in collated sets for printing short-run on a copier (at least that's the way we used to do it). Doing five merges means recombining pages in the right order into a single file, or uncollating the sets, then re-collating after printing.

                               

                              Another possibility, and one I don't particularly like because it wastes toner or ink and can make a mess inside the machine, is to put ALL of the text for all five tabs in each five record set, changing only the central box, and print all five along the edge on all pages. Where there is no paper, the extra simply doesn't show. This would also work for a press sheet and die-cutting after printing, since you would cut off the extras.

                              • 13. Re: InDesign CS5 mailmerge into different text boxes
                                John Hawkinson Level 5

                                Pre-collated sets? Oh, OK.

                                Well then make one master page with the central text and then fields

                                for all five tabs --- a total of six fields.

                                 

                                Then set up your spreadsheet so it looks like this

                                 

                                Center,TAB1,TAB2,TAB3,TAB4,TAB5

                                "first","first","","","",""

                                "second","","second","","",""

                                etc.

                                 

                                that's easy enough in the spreadsheet by making the column B (B2) formula

                                be =IF(MOD(ROW()-1,5)=1,A1,"") and the column C formula be

                                =IF(MOD(ROW()-2,5)=1,A1,"") and keep adjusting the subtracted contstant

                                as you move over.

                                • 14. Re: InDesign CS5 mailmerge into different text boxes
                                  John Hawkinson Level 5

                                  Oops, I meant A2 in those formulas, not A1. Assuming that row 1 is your header row.

                                  Also, instead of -1, -2, -3 as you move over, you could juse use (COLUMN()-1).

                                  • 15. Re: InDesign CS5 mailmerge into different text boxes
                                    Peter Spier Most Valuable Participant (Moderator)

                                    See, that's what I was suggesting in my post # 5. I just didn't know how to get excel to put the data into the right columns.

                                     

                                    Is that really easier than adding tab characters (white space) in front of the merged data after?

                                    • 16. Re: InDesign CS5 mailmerge into different text boxes
                                      John Hawkinson Level 5

                                      Oh, yeah, I see what you mean. I didn't quite get what you meant in post #5.

                                      I think it's a lot easier than adding the tabs in front of the merged data

                                      afterwards, because thinking about threaded textframes can be hard, and it's more annoying to do this kind of postprocessing if you can do it all in one go, and you'd already need to do preprocessing to insert the number of the tab, so better to only have preprocessing and not both pre- and post-.

                                      • 17. Re: InDesign CS5 mailmerge into different text boxes
                                        Peter Spier Most Valuable Participant (Moderator)

                                        I'm not sure you really understood the post processing. In that scenario, you have only one column in the data file. No preprocessing required.

                                         

                                        You put the field place holder in tw positions, once for the center-page frame, and once in a long frame down the edge. For the edge frame you apply a style that has tab stops (in the ordinary sense of what happens when you press the tab key). Post merge you run a script that look for the style, then counts through a loop for the number of "Tabs" (in the sticking out from the page sense), and inserts the correct number of tab characters at the front of the text to push it to the correct position. I would think that you would want to use center-aligned tabs, and have one for each position, so for a 5-tab collection the loop would need to insert first 1, then 2, then 3, then 4, then 5 tabs, then start again. Seems pretty straightforward, but it's been a long time since I wrote code like that.

                                        • 18. Re: InDesign CS5 mailmerge into different text boxes
                                          John Hawkinson Level 5

                                          I had envisioned a hybrid method where each item that should be on tab

                                          2 began with, say, "TAB2," and then you would search-and-replace

                                          "TAB2" with the correct number of tabs.

                                           

                                          Your method works too, but actually involves scripting code. And where

                                          this can be easily done without writing a script, I think that is

                                          better for users who are not familiar with scripting (and even perhaps

                                          for those of us who are), hence the Excel suggestion.

                                           

                                          After all, the data merge input is probably being generated there anyhow.

                                          • 19. Re: InDesign CS5 mailmerge into different text boxes
                                            Peter Spier Most Valuable Participant (Moderator)

                                            John Hawkinson wrote:

                                             

                                            Your method works too, but actually involves scripting code. And where

                                            this can be easily done without writing a script, I think that is

                                            better for users who are not familiar with scripting (and even perhaps

                                            for those of us who are), hence the Excel suggestion.

                                             

                                            Except that the script can be written one time and used for any data set with the correct number of tabs (and would, I think be simple to modify for any number), whereas the excel solution requires preprocessing every data set.

                                            • 20. Re: InDesign CS5 mailmerge into different text boxes
                                              Jeffrey_Smith Most Valuable Participant

                                              IDdatamerge.png

                                              If you could easily restructure your data source as shown above, then you should be able to accomplish this with a datamerge.

                                              1 person found this helpful
                                              • 21. Re: InDesign CS5 mailmerge into different text boxes
                                                Peter Spier Most Valuable Participant (Moderator)

                                                That looks like a pretty good solution, too.


                                                • 22. Re: InDesign CS5 mailmerge into different text boxes
                                                  DCordova Level 1

                                                  That WORKED! Had to do a little tweaking but it worked! I created a master for each bank of tab and inserted the column header in each tab. I had to manually tab the text into columns (I receive a copy of an MSWord Table of Contents) and then apply.

                                                   

                                                  It isn't ideal but it is still FABULOUS and saves me tons of time. Hopefully I will have some more down time to try a scripting method.

                                                   

                                                  Thank you to everyone for your input. Once again I have been blown away.

                                                  Picture1.jpg

                                                  • 23. Re: InDesign CS5 mailmerge into different text boxes
                                                    John Hawkinson Level 5
                                                    That WORKED! Had to do a little tweaking but it worked! I created a master for each bank of tab and inserted the column header in each tab. I had to manually tab the text into columns (I receive a copy of an MSWord Table of Contents) and then apply.

                                                    I don't know what "manually tab the text" means, but I suspect it's a few seconds of work in Excel to correct it. Care to post a screenshot of the before/after?