Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

generating multple copies of a page, based on displayed data 1

Status
Not open for further replies.

flailcozy

Technical User
Dec 4, 2007
18
US
I am trying to figure out a way to have a page repeated (appear twice in the report) if it contains certain data. I have a report that prints customer order items by department. The report is grouped by department, starting a new page for each department from which the items are ordered, and listing those items on the department's page. What I want to do is print a department's page twice if a certain item appears on that page (i.e., has been ordered by a customer). I have a formula that calculates if the item is present on a page, but I don't know how to use it to generate the page twice. Any help would be appreciated.

thanks, jc
 
If department is a group item, and you also show Items as detail lines, I don't think you can do it except by having a subreport in the group footer. Inefficient but there may be no better way.

[yinyang] Madawc Williams (East Anglia, UK). Using Windows XP & Crystal 10 [yinyang]
 
You would have to use a subreport as Madawc suggests, and then use your formula that checks for the presence of the item to conditionally suppress the group footer section.

-LB
 
Thanks for the help--that got me partway there--I was able to get the page to generate a second time. However, the subreport doesn't have any data in it. It is definitely printing the correct department page twice, since the department page header is correct, but the subreport only displays text fields and not the order items. Do I need to do anything special with the subreport links, maybe, to get it to show data the second time?
 
If you saved the report as a subreport, and then placed it in the group footer of the original report and linked it on the group field, you should see the exact same information as in the original report. You would then use a shared variable setup in the main report to conditionally suppress the group footer. Perhaps you did that part incorrectly? Maybe you should explain how you implemented that, showing the content of your formulas.

-LB
 
lbass-

It was the subreport links--now it works perfectly! Thanks so much for your help.

jc
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top