Although grid ++ is easy to create subreports in PULL mode, how should subreports be filled in Push mode?
Scenario: for the appearance of reports, three records must be written when the subreport is empty.
Solution: In the PULL mode, it is obviously not feasible, so you have to write it by yourself.CodeWhen filling a subreport, you must first determine the number of records of the subreport.
Note: When we do this for the first time, we assume that the main report is filled with a record, and then the subreport is associated to fill in the subreport data. But this is not the case with grid ++. It fills in the main report data, then traverses the records in the main report, traverses the data of a main report, and then fills in the subreport.
PASS Parameters: when the main report is filled with data, it will be triggered in the subreport initialize event, you can get the report field value. If there are several pieces of data, the initialize of the subreport will be triggered several times.
Download/files/86188281/gridreportsolution.7z