Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.docmanagement
jose_piratilla jose_piratilla is offline
external usenet poster
 
Posts: 1
Default Disable Header when some style is present in the current page

At the start of new chapters or in some special pages I want to disable the
header. I have different headers for odd and even pages. They are composed of
a text including the page number, the chapter number and the chapter name,
and has a lower border to show a line below it.
I can delete the line from all headers so the problem can be reduced to a IF
field. But I don't know how to ask if in the current field there is present
some style.
I think in using the STYLEREF field to get the current value and store it on
a variable. If this variable changes then it means that the page contains
this style. But it doesn't work well.

  #2   Report Post  
Posted to microsoft.public.word.docmanagement
Suzanne S. Barnhill Suzanne S. Barnhill is offline
external usenet poster
 
Posts: 33,624
Default Disable Header when some style is present in the current page

The only really practical way to do this, I think, is to insert section
breaks between chapters and enable "Different first page." You can then
leave the First Page Header blank.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA

"jose_piratilla" wrote in message
...
At the start of new chapters or in some special pages I want to disable
the
header. I have different headers for odd and even pages. They are composed
of
a text including the page number, the chapter number and the chapter name,
and has a lower border to show a line below it.
I can delete the line from all headers so the problem can be reduced to a
IF
field. But I don't know how to ask if in the current field there is
present
some style.
I think in using the STYLEREF field to get the current value and store it
on
a variable. If this variable changes then it means that the page contains
this style. But it doesn't work well.



  #3   Report Post  
Posted to microsoft.public.word.docmanagement
jose_piratilla[_2_] jose_piratilla[_2_] is offline
external usenet poster
 
Posts: 1
Default Disable Header when some style is present in the current page

Hi Suzanne,

Yes I knew this possibility but it is a lot of manual work. I want a way to
automatize it. I was thinking in a VBA function that reviews a page looking
for some styles. So I could use: { IF IsStylePresent({ PAGE })=1 " " "Bla bla
bla" }

I'm experienced using VBA with access but I don't know anything about the
word document object. Some help?

Thanks.

Suzanne S. Barnhill" wrote:

The only really practical way to do this, I think, is to insert section
breaks between chapters and enable "Different first page." You can then
leave the First Page Header blank.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA

"jose_piratilla" wrote in message
...
At the start of new chapters or in some special pages I want to disable
the
header. I have different headers for odd and even pages. They are composed
of
a text including the page number, the chapter number and the chapter name,
and has a lower border to show a line below it.
I can delete the line from all headers so the problem can be reduced to a
IF
field. But I don't know how to ask if in the current field there is
present
some style.
I think in using the STYLEREF field to get the current value and store it
on
a variable. If this variable changes then it means that the page contains
this style. But it doesn't work well.




  #4   Report Post  
Posted to microsoft.public.word.docmanagement
Stefan Blom Stefan Blom is offline
external usenet poster
 
Posts: 8,428
Default Disable Header when some style is present in the current page

Ask in a programming newsgroup such as microsoft.public.word.vba.general; if
there is a way to do this with a macro, I'm sure someone there can figure it
out.

--
Stefan Blom
Microsoft Word MVP


"jose_piratilla" wrote in message
...
Hi Suzanne,

Yes I knew this possibility but it is a lot of manual work. I want a way
to
automatize it. I was thinking in a VBA function that reviews a page
looking
for some styles. So I could use: { IF IsStylePresent({ PAGE })=1 " " "Bla
bla
bla" }

I'm experienced using VBA with access but I don't know anything about the
word document object. Some help?

Thanks.

Suzanne S. Barnhill" wrote:

The only really practical way to do this, I think, is to insert section
breaks between chapters and enable "Different first page." You can then
leave the First Page Header blank.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA

"jose_piratilla" wrote in
message
...
At the start of new chapters or in some special pages I want to
disable
the
header. I have different headers for odd and even pages. They are
composed
of
a text including the page number, the chapter number and the chapter
name,
and has a lower border to show a line below it.
I can delete the line from all headers so the problem can be reduced to
a
IF
field. But I don't know how to ask if in the current field there is
present
some style.
I think in using the STYLEREF field to get the current value and store
it
on
a variable. If this variable changes then it means that the page
contains
this style. But it doesn't work well.






Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Header formula to display current "Heading 1" at the top of each page Scott Lolmaugh Formatting Long Documents 2 April 18th 08 12:13 AM
Bibliography includes citations not present in current document! StefM Microsoft Word Help 0 December 13th 07 05:00 PM
Current Style Control Maxim Microsoft Word Help 1 January 21st 07 02:43 AM
Current list number in Page Header [email protected] Microsoft Word Help 1 October 20th 06 03:59 PM
Disable header & footer from page 2 Ray Page Layout 5 November 16th 05 02:39 PM


All times are GMT +1. The time now is 01:22 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"