Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Printing a Large number of pages
Message
From
05/10/2002 12:56:26
 
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00708040
Message ID:
00708082
Views:
10
It does not really matter, while or for

More important is that you do not print any bill twice

suggest you change the between into
where ( reccno() between (i) and (i + lnBatchSize -1) )


>I would use FOR loop.
lnBatchSize = 5000
>FOR i=1 TO Reccount( "YourCursorName" ) STEP lnBatchSize
>	Select * From YourTable ;
>		Where Reccno() BETWEEN i And i + lnBatchSize ;
>		Into Cursor YourCursorName
>	Report Form MyReport To Printer
>ENDFOR
>
>>I would do something like this:
>>
>>
>>i = 1
>>Do While .T.
>>
>>	Select * From YourTable Where Reccno() > = i And Recno() <= i + 10000 ;
>>		Into Cursor YourCursorName
>>	i = i + 10000
>>
>>	If Reccount( "YourCursorName" ) > 0
>>		Report Form MyReport To Printer
>>	Else
>>		Exit
>>	EndIf
>>
>>EndDo
>>
>>
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform