B
bts
Hello
I would like to put some info from vba code to the footer
here you are my code colleted it from some article
But my problem is that, if the view was "print layout" the macr
wil
it turn to the normal view, and switch on the footer panel
In any other case it will only switch the footer panel o
I would like to insert the info to the all footer without changing the screen
Any help would be appreciate
Public Sub AddFooterAndPrint(
Application.ScreenUpdating = Fals
ActiveDocument.Sections(ActiveDocument.Sections.Count).Footers(wdHeaderFooterPrimary).Range.Selec
With Selectio
.Paragraphs(1).Alignment = wdAlignParagraphCente
.TypeText Text:="page "
.Fields.Add Range:=Selection.Range, Type:=wdFieldEmpty, Text:="Pag
"
PreserveFormatting:=Tru
.TypeText Text:=" per "
.Fields.Add Range:=Selection.Range, Type:=wdFieldEmpty, Text:="NUMPAGE
", PreserveFormatting:=Tru
.TypeText Text:=" " & LoggedInUserName() & " "
End Wit
Application.ScreenUpdating = Tru
End Sub
I would like to put some info from vba code to the footer
here you are my code colleted it from some article
But my problem is that, if the view was "print layout" the macr
wil
it turn to the normal view, and switch on the footer panel
In any other case it will only switch the footer panel o
I would like to insert the info to the all footer without changing the screen
Any help would be appreciate
Public Sub AddFooterAndPrint(
Application.ScreenUpdating = Fals
ActiveDocument.Sections(ActiveDocument.Sections.Count).Footers(wdHeaderFooterPrimary).Range.Selec
With Selectio
.Paragraphs(1).Alignment = wdAlignParagraphCente
.TypeText Text:="page "
.Fields.Add Range:=Selection.Range, Type:=wdFieldEmpty, Text:="Pag
"
PreserveFormatting:=Tru
.TypeText Text:=" per "
.Fields.Add Range:=Selection.Range, Type:=wdFieldEmpty, Text:="NUMPAGE
", PreserveFormatting:=Tru
.TypeText Text:=" " & LoggedInUserName() & " "
End Wit
Application.ScreenUpdating = Tru
End Sub