问题
I am using the following expression to only display some text in my report header only for the first page of the report
=IIF(Globals!ExecutionTime = 1, "My Text Here", Nothing)
But this means on all the subsequent pages at the top of the report there is just some empty space where the text should be, see below
1st page:
---------------------------------------------------------------
My Text Here
---------------------------------------------------------------
Rest of the report
Subsequent pages:
---------------------------------------------------------------
---------------------------------------------------------------
Rest of the report
What I would like if it is even possible for the first page to remain how I currently have it set up and the subsequent pages to be shifted up to fill the empty space that is left when the text is not present on all pages after the first
Wanted to know how I could remove the empty space that the header used to occupy and doing showing the header based on output of an expression rather than showing specific text solved this issue
回答1:
Right click on your textbox Textbox properties > Visibility > Show or hide based on expression and add the following expression:
=IIF(Globals!PageNumber = 1, FALSE, TRUE)
You have to do this for all items (textboxes, images) that are in the header.
来源:https://stackoverflow.com/questions/52715263/ssrs-report-header