[AccessD] Force new page from Subreport Qty

Robin Lawrence rgilimited at btconnect.com
Wed Jun 2 03:41:50 CDT 2004


I have a standard type report based on Order / Order Line tables  with
Order Report [WHD_Ord] and Order Line Subreport [WHD_Line_Sub] - no
sorting or grouping in either report.
 
I need to force a new page whenever the sum of [Qty] field in
[WHD_Line_Sub] >= 3 .
(ie no more than 3 items allowed per page)
 
I have got so far:
Add Text box in [WHD_Line_Sub]
Name = RunSum 
Control Source = [Qty] 
Running Sum = Over All
 
On [WHD_Line_Sub] Detail Format event :
Dim x as long
x = me.RunSum
If x >= 3 then
??Force new Page here
x = 0 
End If
 
On [WHD_Ord] Page Footer Print Event
??Reset me.RunSum = 0 
 
Having trouble working out how to do the two items prefixed ??
Can anyone suggest the correct syntax or am I going about it the wrong
way?
 
 
Regards
Robin Lawrence
robin at rolledgold.co.uk
 



More information about the AccessD mailing list