Sometimes you may like to hide some section of a report when running it in Excel/ PDF output format. One way to do this might be to create a render variable based on the ReportOutput() function, and hide the object that way. Some objects, however don't support a render variable.
You can use (Don't Print) class to hide any item in a Cognos report. The (Don't Print) class will exclude the item from the output. Here are the steps to take
- Select the object which you want to hide
- click on Classes property under Properties pane
- Select (Don't Print) class under Global Classes list
- Save and run the report