A set location for the Report summary

dcavaiani

Registered User.
Local time
Yesterday, 22:06
Joined
May 26, 2014
Messages
385
Code:
 Private Sub DummyGroupFooter_Format(Cancel As Integer, FormatCount As Integer)
Dim footerPos As Long
' Dim countspace As Long
' countspace = countspace + 1
footerPos = 7.6 * 1440   'desired position of footer in inches * 1440 twips per inch)
    If Me.Top < footerPos Then
        Me.DummyGroupFooter.Height = footerPos - Me.Top
 
    Else
        Me.DummyGroupFooter.Height = footerPos
     End If
    
End Sub[code]

The code above allows me to always print the Invoice Summary at a SET location toward the bottom of the page.   The invoice can have a variable number of detail lines.  The invoice has some vertical column/grid lines between columns of the detail.  IS THERE ANY way to code the above so that the vertical lines can appear continuously down the page - all the way down to the start of the summary section ??
 
Hi. Which vertical lines were you referring to? Did you draw these lines on the report? Or, did you add these lines using code?
 
Hi. Which vertical lines were you referring to? Did you draw these lines on the report? Or, did you add these lines using code?

They are lines drawn on the detail report section ...
 
They are lines drawn on the detail report section ...
Okay, thanks. Have you tried modifying their height properties in the Format property of the Detail section? Just a thought...
 
No good as in they don't change or something else?

If I change the height of the Detail vertical lines, then the detail section just stretches way down the page for each detail line record. Some kind of modified code is needed in the Dummy Section.
 
You may need to calculate where the last detail line ends, then make the footer taller and have lines in the footer also. I haven't tried this before though.
 
If I change the height of the Detail vertical lines, then the detail section just stretches way down the page for each detail line record. Some kind of modified code is needed in the Dummy Section.
Okay, I think I am starting to understand it now. Are you able to post a demo copy of your db, so we can play around with it?
 
How do I post the only the Table and the report ?

Create a new DB.
Import ONLY the report and the table into the new DB.
Delete all records that you don't want others to see and add in some sample data.
Compact/Repair then upload.
 
Please don't forget to zip it up. Thank you.
 
Will you normally have more than one page for your invoice?
 
I think the trick will be to use your Report Page Footer. You will put in your lines there since it is normally 0 height. Count the number of matching records when you open the report (so you'll know how tall to make it on the LAST page) and keep a running total in the report's details. Once you are on the last record, set the Report Page Footer and your vertical line's height based on the number lines you have for that (last) page.

The fun part is counting it all. Got kinda busy so I can't do it at the moment, but if I get some time a little later I'll see what I can whip up.
 

Users who are viewing this thread

Back
Top Bottom