As I stated in the headline, I want to be able to run the report and see if It is returning rows or not. (empty or has data)
The background is that I am exporting reports data. So I need to know when the report is empty, in order to avoid the export of the empty report because I end up with HTML data in the report instead of rows. I want to avoid that and make it more user friendly.
I investigated a below result from Reports.ReportResults object and did not found anything that could be used as a solid flag for this case.
Reports.ReportResults results = Reports.ReportManager.runReport(reportId, true); System.debug(results);
Any help or idea would be appreciated.