12 Replies Latest reply on May 30, 2011 1:32 PM by Stix Hart

    Anyone want to do a job?

    Stix Hart Level 5

      I apologise in advance if this is inappropriate but I have a challenge that I'm wondering if it is possible to automate.  I've also posted it as a question on the InDesign forum here but I think it will only be able to solved by scripting.  So if someone thought it was possible (I also need it in the next 24 hours to make use of it) and was willing to PM me with a quote that would be great.


      What I want to do is take a list like this (it would come from Excel and have more entries across the page beside each name):





























      Now say the page is only long enough to go half way through  Manchester where it breaks I want it to say Manchester continued at the  top of the next page like this:


      Manchester continued







      There is a space at the end of each list segment before the next segment  starts.  The text that is put in would have to come from the name at  the top of the list segment, so in the above example it would have to  look backwards, see "Manchester" and put in "Manchester continued" at  the top of the new page.  Ideally it would also fix the problem that occurs when the heading is at the bottom og a page and the text start at the top of the next by forcing the heading onto the next page.

        • 1. Re: Anyone want to do a job?
          Harbs. Level 6

          Depending on your exact situation, you might be able to do this with Power Headers:




          • 2. Re: Anyone want to do a job?
            Stix Hart Level 5

            Thanks Harbs, I hadn't though of using an existing tool like that.  I've downloaded a trial and played around with it but I don't think it will work.  Below is a sample of what I want it looks like now once I've imported it as regular tagged text and applied a paragraph style to the whole thing then used GREP to find and format the headers with another style.  Now what I want to happen is for Arsenal continued to be inserted at the top of the second page.





            • 3. Re: Anyone want to do a job?
              Harbs. Level 6



              You can do it with a "Current Instance" and a conditional "continued" text.


              You can wipe out the non-continued text using a GREP Processor (with a negative lookahead).


              The GREP would look something like this:

              ^\w+(?! continued)



              • 4. Re: Anyone want to do a job?
                Stix Hart Level 5

                Sorry, I'm way out of my depth here...  You lost me after "You can do it", can you repeat the rest a little slower?

                • 5. Re: Anyone want to do a job?
                  Harbs. Level 6

                  Here's it again in pictures...



                  • 6. Re: Anyone want to do a job?
                    Stix Hart Level 5

                    OK I was doing a few things wrong there.  I redid it but with that GREP processor it did "l continued" where "l" was the end of Arsenal.  Doing it without that processor worked better but still needs a bit of refining.


                    I've posted sample files here showing how it needs to end up.  If I can't get it so that it automatically pushes a header over on to the next page when it falls at the bottom that's not a big deal, I could manually put an extra return in and update the headers.


                    I'm going to have to call it a night as it's after 11PM here and I have to be up at 5 tomorrow.  Would you be able to continue the discussion then?  I'm sure I can persuade the boss to pay you something for your time as well as the script if we can do this successfully.

                    • 7. Re: Anyone want to do a job?
                      Harbs. Level 6

                      Yeah. The GREP needed a bit more tweaking...


                      Here's the file set up. It does not push down the text. If you need that, you can accomplish that by adding a line return into the text before and setting the text frame to expand in AutoFlow Pro. (The text frame would need a text wrap applied as well.)





                      • 8. Re: Anyone want to do a job?
                        Stix Hart Level 5

                        Very cool indeed.  But how about when a list segment ends at the bottom of a page?  As it's set up now the header still displays a continued from the previous page like this:




                        In this case what needs to happen is it needs to say "Real Madrid" (without continued after it) where it says "Chelsea continued".  Ideally it would take out the space too, is there a GREP expression that could find that space when it is at the beginning of a text frame?


                        Now it's 12:30, I really should try and switch off!

                        • 9. Re: Anyone want to do a job?
                          Stix Hart Level 5

                          P.S. I don't quite get what you mean about adding a line break and using AutoFlow Pro?  I was going to just manually add a line break to force it down anyway?  As long as the previous problem can be solved of course.

                          • 10. Re: Anyone want to do a job?
                            Harbs. Level 6

                            I'm not sure what your situation is there, but you might need this option:


                            Is that a separate story? Where's that space coming from?


                            There's very little that can't be done using Power Headers, but as things get complex, the setup can too...



                            • 11. Re: Anyone want to do a job?
                              Stix Hart Level 5

                              No, that doesn't fix it.  That space occurs when the page before looks like this:




                              When it looks like this the header is then blank but like my previous example needs to say Arsenal with no continued.




                              It's these two occasions where the empty line is either at the beginning or end of a page that throw it.

                              • 12. Re: Anyone want to do a job?
                                Stix Hart Level 5

                                If you do get a chance to look at this tomorrow Harbs that would be awesome.  I should also mention that the headers don't have to stay live, these are not documents that get edited at all.  The data comes off a server, gets processed and then gets printed.  So if there was some way to go through the document fixing up the above problems it wouldn't matter if it broke the automation at the same time.