I have a report with a subreport. I have declared a shared stringvar which I want to use to pass a value from the subreport to the main. I have a formula {@ChangeSame}that shows where the next record is different. It says 'Same' or 'Change'. The show formula says
whileprintingrecords;
shared stringvar Pass := {@ChangeSame}
I want it to pick up the first records {@ChangeSame} value but it picks up the last one which is blank. If I change the @ChangeSame formula to previous record it will pick up the last record which can be wrong ie in these cases
For Next @ChangeSame
1 George School Change
2 Fred School Same
3 Fred School
Show = Blank (Incorrect)
For Next @Change Same
1 David School Change
2 Martin School
Show = Blank (Incorrect)
For Previous @ChangeSame
1 George School
2 Fred School Change
3 Fred School Same
Show = Same (Incorrect)
For Previous @ChangeSame
1 David School
2 Martin School Change
Show Change (Correct)
I only want to compare the first two schools in the list and can suppress the others but the formula still looks at all the records. I have tried using minimum in the show field but it won't allow me.
Any ideas? Learn something new every day *:->*
whileprintingrecords;
shared stringvar Pass := {@ChangeSame}
I want it to pick up the first records {@ChangeSame} value but it picks up the last one which is blank. If I change the @ChangeSame formula to previous record it will pick up the last record which can be wrong ie in these cases
For Next @ChangeSame
1 George School Change
2 Fred School Same
3 Fred School
Show = Blank (Incorrect)
For Next @Change Same
1 David School Change
2 Martin School
Show = Blank (Incorrect)
For Previous @ChangeSame
1 George School
2 Fred School Change
3 Fred School Same
Show = Same (Incorrect)
For Previous @ChangeSame
1 David School
2 Martin School Change
Show Change (Correct)
I only want to compare the first two schools in the list and can suppress the others but the formula still looks at all the records. I have tried using minimum in the show field but it won't allow me.
Any ideas? Learn something new every day *:->*