4 Replies Latest reply on May 19, 2010 4:30 PM by nolak37

    Printing an optional second page



      Printing an optional second page


      Hello everyone,


      Im trying to print information from one of my table onto a pre-printed business form

      (there is no option arround this the form is standard for the businessand printed with some type of special ink)


      this print layout includes information from 2 tables, I got it to where the page prints out correctly but I found 1 problem, the form has 6 fields to hold info on what the person was charged for but there are cases where there are actually more "charge" records than 6. when this happens I need to print 2 pages (forms) both will hold the same person information but the first thould print charge 1-6 and the second charge 7-12.


      Has anyone ever done anything like this?

      is this even possible?


      i thought of making one long layout where the information is duplicated but the problem is that if a person only has 1 or 2 charges it will still print 2 sheets filling both with persons info but the second would have no charges.

        • 1. Re: Printing an optional second page

          Are you printing this one form at a time or are you printing an entire batch at once?


          Are you recordig the charges in a separate related table like a typical invoice does?


          If the charges are in related records, you can use the count function to determine whether you need one page or two. You could then use that information to switch between a one and two page version of the layout.

          • 2. Re: Printing an optional second page

            At the moment I have it set up to print 1 page at a time but was going to try and set this up to print a batch at the end of the day (as soon as i figured out how to do so) if you could guide me in the right direction for this id appreciate it.


            The charges are being recorded to a related table.


            I hadnt thought of using count function with 2 layouts but is sounds like it might do the trick.

            I've never used that function so im guessing on this.


            If[Get ( FoundCount ) >6

               Go to Layout [ 2PageLayout ]


               Go to Layout [ 1PageLayout]

            End If

            Enter Preview Mode []


            Does that look correct or am i missing something?


            Thanks Phil

            • 3. Re: Printing an optional second page

              That's not the function I had in mind.


              I'm suggesting:


              If [ Count( ChargesTable::nonblankfield) > 6 ]

                Go to layout [2 page layout]


                Go to layout [1 page layout]

              ENd if

              Print [Restore] //specify current record if you have more than one record in your found set.

              • 4. Re: Printing an optional second page

                Got it,


                Thanks a lot Phil, you successfully saved me from a very large head ache, lol.