I just created a stripped down sample report, and the issue with using page break after went away, but the other issue remains. I have a parameter named PageBreak with three option values: NONE, GROUP1, and GROUP2. When i choose NONE, it should always evaluate the Group1pre and Group2pre as ="" and therefore never cause a page break during the report. Unfortunately, it still causes the GROUP1 page breaks even if I choose NONE.
I created four group levels sequenced as follows (as seen in the Groups tab of Table Properties) and a detail row with the Detail values:
table1_Group1pre, page break at end checked, group expression =IIF(Parameters!PageBreak.Value="GROUP1",Fields!Group1.Value,"")
table1_Group1, no page breaks, group expression =Fields!Group1.Value
table1_Group2pre, page break at end checked, group expression =IIF(Parameters!PageBreak.Value="GROUP2",Fields!Group2.Value,"")
table1_Group2, no page breaks, group expression =Fields!Group2.Value
Here is the data set I created for testing.
select 'ABC' as Group1, '123' as Group2, 'slfje' as Data
union all
select 'ABC' as Group1, '123' as Group2, 'redfg' as Data
union all
select 'ABC' as Group1, '123' as Group2, 'wqsde' as Data
union all
select 'ABC' as Group1, '456' as Group2, 'rdrgd' as Data
union all
select 'ABC' as Group1, '456' as Group2, 'f5e4s6' as Data
union all
select 'ABC' as Group1, '789' as Group2, 'rhfth' as Data
union all
select 'ABC' as Group1, '789' as Group2, 'effgfg' as Data
union all
select 'DEF' as Group1, '987' as Group2, 'kuhjg' as Data
union all
select 'DEF' as Group1, '987' as Group2, 'efjklrg' as Data
union all
select 'DEF' as Group1, '987' as Group2, 'euurio' as Data
union all
select 'DEF' as Group1, '654' as Group2, 'wesdf' as Data
union all
select 'GHI' as Group1, '789' as Group2, 'yghfg' as Data
union all
select 'GHI' as Group1, '789' as Group2, '56215hh' as Data
union all
select 'GHI' as Group1, '456' as Group2, 'hbvfg' as Data
union all
select 'GHI' as Group1, '456' as Group2, 't456e4w' as Data
union all
select 'GHI' as Group1, '123' as Group2, 'ouuyf' as Data
union all
select 'GHI' as Group1, '123' as Group2, '5f4g8r9' as Data
union all
select 'GHI' as Group1, '123' as Group2, 'zzzzzzzz' as Data