Section Header on report

M

Microsoft

Access 2007

I have a report with a header section which I have set to repeating so that
it appears on each page.

Is there a way of adding the words "Continued" to the header section when it
is repeated on a new page.

eg
Page 1
Section 1
iten
item
item
Page 2
Section 1 continued
item
item
Section 2
item
Page 3
Section 2 continued
item
Section 3
item
item
etc

thanks
 
M

Marshall Barton

Microsoft said:
Access 2007

I have a report with a header section which I have set to repeating so that
it appears on each page.

Is there a way of adding the words "Continued" to the header section when it
is repeated on a new page.

eg
Page 1
Section 1
iten
item
item
Page 2
Section 1 continued
item
item
Section 2
item
Page 3
Section 2 continued
item
Section 3
item


Add a text box (named txtLine) to the detail setcion. Set
its control source to =1 and RunningSum to Over Group.

Then the group header section's text box can use an
expression like:
=[grouping field] & IIf(txtLine > 1, " (continued)", "")
 
M

Microsoft

Thanks but this doesn't work

The report Headers are:

SectionNo Header
ItemNo Header
DetailSection
ItemNoFooter
SectionNoFooter

within SectionNo Header I want the field [Section] to print with the added
'continued' if it goes over to two pages.

the problem I have is that Name? comes up in the SectionNo Header
here is what I typed in the ControlSource of txtSection

=[Section] & IIf([txtLine]>1," continued","")

and the Running Sum seems to increment for each detail record

Any ideas?
Thanks again
Marshall Barton said:
Microsoft said:
Access 2007

I have a report with a header section which I have set to repeating so
that
it appears on each page.

Is there a way of adding the words "Continued" to the header section when
it
is repeated on a new page.

eg
Page 1
Section 1
iten
item
item
Page 2
Section 1 continued
item
item
Section 2
item
Page 3
Section 2 continued
item
Section 3
item


Add a text box (named txtLine) to the detail setcion. Set
its control source to =1 and RunningSum to Over Group.

Then the group header section's text box can use an
expression like:
=[grouping field] & IIf(txtLine > 1, " (continued)", "")
 
M

Marshall Barton

I don't see where the Name? error is coming from.

My simple technique will not work with two levels of
grouping. I am going to have take some time to think about
a way to deal with your situation.
--
Marsh
MVP [MS Access]

Thanks but this doesn't work

The report Headers are:

SectionNo Header
ItemNo Header
DetailSection
ItemNoFooter
SectionNoFooter

within SectionNo Header I want the field [Section] to print with the added
'continued' if it goes over to two pages.

the problem I have is that Name? comes up in the SectionNo Header
here is what I typed in the ControlSource of txtSection

=[Section] & IIf([txtLine]>1," continued","")

and the Running Sum seems to increment for each detail record


Microsoft said:
Access 2007

I have a report with a header section which I have set to repeating so
that
it appears on each page.

Is there a way of adding the words "Continued" to the header section when
it
is repeated on a new page.

eg
Page 1
Section 1
iten
item
item
Page 2
Section 1 continued
item
item
Section 2
item
Page 3
Section 2 continued
item
Section 3
item


Add a text box (named txtLine) to the detail setcion. Set
its control source to =1 and RunningSum to Over Group.

Then the group header section's text box can use an
expression like:
=[grouping field] & IIf(txtLine > 1, " (continued)", "")
 
M

Marshall Barton

I think all we need is to add another =1 running sum text
box (named txtItemLine) to the Item group header.

Then change the Section text box expression to:

=[Section] & IIf([txtLine]>1 Or txtItemLine>1,"
continued","")

(Note: make sure that theSection text box is **not** named
Section)

Did you figure out where the Name? error is coming from?

I have not tested this in A2007 so I can't guarantee there
is nothing in the repeat section processing that's different
from A2003.
--
Marsh
MVP [MS Access]

Thanks but this doesn't work

The report Headers are:

SectionNo Header
ItemNo Header
DetailSection
ItemNoFooter
SectionNoFooter

within SectionNo Header I want the field [Section] to print with the added
'continued' if it goes over to two pages.

the problem I have is that Name? comes up in the SectionNo Header
here is what I typed in the ControlSource of txtSection

=[Section] & IIf([txtLine]>1," continued","")

and the Running Sum seems to increment for each detail record

Any ideas?
Thanks again
"Marshall Barton"wrote
Microsoft said:
Access 2007

I have a report with a header section which I have set to repeating so
that
it appears on each page.

Is there a way of adding the words "Continued" to the header section when
it
is repeated on a new page.

eg
Page 1
Section 1
iten
item
item
Page 2
Section 1 continued
item
item
Section 2
item
Page 3
Section 2 continued
item
Section 3
item


Add a text box (named txtLine) to the detail setcion. Set
its control source to =1 and RunningSum to Over Group.

Then the group header section's text box can use an
expression like:
=[grouping field] & IIf(txtLine > 1, " (continued)", "")
 
M

Microsoft

The Name? error was because Section is a reserved word.

It worked if I just added the running sum to the Item Header and left syntax
as =[grouping field] & IIf(txtItemLine > 1, " (continued)", "")

Thanks for your help

Alison
Marshall Barton said:
I think all we need is to add another =1 running sum text
box (named txtItemLine) to the Item group header.

Then change the Section text box expression to:

=[Section] & IIf([txtLine]>1 Or txtItemLine>1,"
continued","")

(Note: make sure that theSection text box is **not** named
Section)

Did you figure out where the Name? error is coming from?

I have not tested this in A2007 so I can't guarantee there
is nothing in the repeat section processing that's different
from A2003.
--
Marsh
MVP [MS Access]

Thanks but this doesn't work

The report Headers are:

SectionNo Header
ItemNo Header
DetailSection
ItemNoFooter
SectionNoFooter

within SectionNo Header I want the field [Section] to print with the
added
'continued' if it goes over to two pages.

the problem I have is that Name? comes up in the SectionNo Header
here is what I typed in the ControlSource of txtSection

=[Section] & IIf([txtLine]>1," continued","")

and the Running Sum seems to increment for each detail record

Any ideas?
Thanks again
"Marshall Barton"wrote
Microsoft wrote:

Access 2007

I have a report with a header section which I have set to repeating so
that
it appears on each page.

Is there a way of adding the words "Continued" to the header section
when
it
is repeated on a new page.

eg
Page 1
Section 1
iten
item
item
Page 2
Section 1 continued
item
item
Section 2
item
Page 3
Section 2 continued
item
Section 3
item


Add a text box (named txtLine) to the detail setcion. Set
its control source to =1 and RunningSum to Over Group.

Then the group header section's text box can use an
expression like:
=[grouping field] & IIf(txtLine > 1, " (continued)", "")
 
M

Marshall Barton

Microsoft said:
The Name? error was because Section is a reserved word.

It worked if I just added the running sum to the Item Header and left syntax
as =[grouping field] & IIf(txtItemLine > 1, " (continued)", "")


Grrrrr, I should have caught the reserved word problem.

That expression is not sufficient because txtItemLine will
be 1 at the start of each new item. So, you will not get
continued if a new item just happens to start on a new page.
The second running sum text box and the modifed expression I
posted will guard against that situation.
 
M

Microsoft

If I put the the running sum on the Detail line as well the 'continued'
never appears.
The report is 13 pages long and seems to work fine with just the ItemHeader
having the running sum...........


Marshall Barton said:
Microsoft said:
The Name? error was because Section is a reserved word.

It worked if I just added the running sum to the Item Header and left
syntax
as =[grouping field] & IIf(txtItemLine > 1, " (continued)", "")


Grrrrr, I should have caught the reserved word problem.

That expression is not sufficient because txtItemLine will
be 1 at the start of each new item. So, you will not get
continued if a new item just happens to start on a new page.
The second running sum text box and the modifed expression I
posted will guard against that situation.
 
M

Marshall Barton

If don't have a running sum text box in both the Item group
header and the detail, then you might also be missing
"continued" if the first item in a section spills onto a
second page.
--
Marsh
MVP [MS Access]

If I put the the running sum on the Detail line as well the 'continued'
never appears.
The report is 13 pages long and seems to work fine with just the ItemHeader
having the running sum...........


Microsoft said:
The Name? error was because Section is a reserved word.

It worked if I just added the running sum to the Item Header and left
syntax
as =[grouping field] & IIf(txtItemLine > 1, " (continued)", "")


Grrrrr, I should have caught the reserved word problem.

That expression is not sufficient because txtItemLine will
be 1 at the start of each new item. So, you will not get
continued if a new item just happens to start on a new page.
The second running sum text box and the modifed expression I
posted will guard against that situation.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top