At desig time. Select the sections that should be included in the export.
You need a property on the sections and the controls on the report that tells if it should be included in the export or not.
Today, when you export a report to excel the report is bloated with formatting. The end user must use a lot of time trying to clean up excel sheet before it can be used. Removing page footers and headers and unwanted columns as a result of the messed up formatting.
Running the report twice using hiding is not a good solution.