March 6th, 2014, 09:34 AM
In a quandary, I have a record, prior to working on this record I need to run a subreport to share a number that will determine what becomes of the present record, based on that do whatever is determined, and proceed to the next record...till end of file.
Problem is the shared number produced by the subreport shows up a record late...iow, it acts on the next record not the one that it is called from.
Is there a way to do this or simply a limitation?
Last edited by leburg; March 6th, 2014 at 09:35 AM.
Reason: add info
March 10th, 2014, 09:37 AM
There are a few limits to CR, one is evaluation time. Not trying to overstate the obvious but you can't read a record before you read the record. Sometimes you can use multiple sub-reports, i.e. run the sub-report to determine you key value, read a record in the main report, then pass values from the first sub-report and the record to another sub-report to do the processing. Sounds a bit heavy. Another option is to build a stored procedure to do the work.
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!