<p><a href="http://www.nevrona.com/" rel="nofollow noreferrer">Nevrona Designs'</a> <a href="http://www.nevrona.com/Products/RaveReports/StandardEdition/tabid/66/Default.aspx" rel="nofollow noreferrer">Rave Reports</a> is a Report Engine for use by <a href="http://www.embarcadero.com/" rel="nofollow noreferrer">Embarcadero's</a> <a href="http://www.codegear.com/products/delphi/win32" rel="nofollow noreferrer">Delphi</a> IDE.</p>

<p>This is what I call the Rave Endless Loop bug. In Rave Reports
version 6.5.0 (VCL10) that comes bundled with Delphi 2006, there is a
nortorious bug that plagues many Rave report developers. If you have a
non-empty dataset, and the data rows for this dataset fit exactly into a
page (that is to say there are zero widow rows), then upon PrintPreview,
Rave will get stuck in an infinite loop generating pages.</p>

<p>This problem has been previously reported in this newsgroup under the
following headings:</p>

<ol>
<li>"error: generating infinite pages"; Hugo Hiram 20/9/2006 8:44PM</li>
<li>"Rave loop bug. Please help"; Tomas Lazar 11/07/2006 7:35PM</li>
<li>"Loop on full page of data?"; Tony Chistiansen 23/12/2004 3:41PM</li>
<li>reply to (3) by another complainant; Oliver Piche</li>
<li>"Endless lopp print bug"; Richso 9/11/2004 4:44PM</li>
</ol>

<p>In each of these postings, there was no response from Nevrona, and no
solution was reported.</p>

<p>Possibly, the problem has also been reported on an allied newsgroup
(nevrona.public.rave.reports.general), to wit:
6. "Continuously generating report"; Jobard 20/11/2005
Although it is not clear to me if (6) is the Rave Endless loop bug or
another problem. This posting did get a reply from Nevrona, but it was
more in relation to multiple regions ("There is a problem when using
multiple regions that go over a page-break.") than the problem of zero
widows.</p>

[{'answer_id': 68950, 'author': 'Sean B. Durkin', 'author_id': 10823, 'author_profile': 'https://Stackoverflow.com/users/10823', 'pm_score': 3, 'selected': True, 'text': '<p>This is more of a work-around than a true solution. I first posted this work-around on the Nevrona newsgroup (Group=nevrona.public.rave.developer.delphi.rave; Subject="Are you suffering from the Rave Endless Loop bug?: Work-around announced."; Date=13/11/2006 7:06 PM)</p>\n\n<p>So here is my solution. It is more of a work-around than a good\nlong-term solution, and I hope that Nevrona will give this issue some\nserious attention in the near future.</p>\n\n<ol>\n<li>Given your particular report layout, count the maximum number of rows\nper page. Let us say that this is 40.</li>\n<li>Set up a counter to count the rows within the page (as opposed to rows within the whole report). You could do this either by event script or by a CalcTotal component.</li>\n<li>Define an OnBeforePrint scripted event handler for the main data band.</li>\n<li>In this event handler set the FinishNewPage property of the main data band to be True when the row-per-page count is one or two below the max (in our example, this would be 38). And set it to False in all other cases. The effect of this is to give every page a non-zero number of widows (in this case 1..38), thus avoiding the condition that gives rise to the Rave Endless loop problem.</li>\n</ol>\n'}, {'answer_id': 475100, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': 1, 'selected': False, 'text': "<p>Thanks so much for this Sean - unfortunately this wouldn't work for me but I came up with another solution...\nYou see I have a memo at the top of the region that might expand or contract depending on how many notes the user has left in the database. This means that the number of rows that can fit on a page varies.\nHowever. there is another solution - you use the MaxHeightLeft property of a databand.\nAll you do is measure the height of your databand, multiply it by 2, and put this in your MaxHeightLeft property. This will force 1 or 2 records onto the next page if it fills up that much.</p>\n"}, {'answer_id': 1116391, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': 0, 'selected': False, 'text': "<p>thank's a lot, this thread helps me out from my problem with endless printing loop in Nevrona Rave...., I set MinHeightLeft to 0,500, this setting is work but i'm not sure that it will work for anothers result set of my query report.</p>\n"}, {'answer_id': 3093234, 'author': 'Fabiola Herrera', 'author_id': 373171, 'author_profile': 'https://Stackoverflow.com/users/373171', 'pm_score': 0, 'selected': False, 'text': '<p>Master, \nThe solution is MinHeightLeft to 0,500   , i use property wastefit area in true and generated the loop in the second print,  but when changed the property MinHeightLeft to 0,500 the error disapear.</p>\n\n<p>Thanks !</p>\n\n<p>Atte\nFabiola Herrera.\nFabi_ucv@hotmail.com</p>\n'}]
['https://Stackoverflow.com/questions/68929', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/10823/']