Run RTC Reports From Classic

hi everyone, i’m back after some time with a new and easy trick for the laziest programmers…

when developing reports for the 3 tier client, we are going to make a lot of tests because of their complexity and because they are error prone.

This approach lead us to make something like 50-100 runs per report in order to check the layout after every change. Unfortunately we would need an action to run our report. I found an easy and simple way to make the whole thing faster:

create a new page with only a container, and put this code in the onopen trigger
REPORT.RUNMODAL(REPORT::"myreportname");
COMMIT;
ERROR('');

Now, the only thing you have to do is to run the page: the commit makes sure that if your report is modifying something, it will be saved. this is necessary because we have the ERROR(”) that closes the page (the currpage.close does not work) that would lead to an unwanted rollback.

It’s a quit stupid trick, but saves some time in day to day work.

Enjoy

Leave a Reply

*
To prove you're a person (not a spam script), type the security text shown in the picture. Click here to regenerate some new text.
Click to hear an audio file of the anti-spam word