Numerar paginas en word
Publicado por Ivan (1 intervención) el 17/10/2016 15:05:32
Buenas tardes,
Tengo un pie de página hecho en word con VB. Y resulta que quisiera que añadiera el número de página actual, el problema es que siempre me pone el mismo número, no incrementa.
Muchas gracias de antemano
Tengo un pie de página hecho en word con VB. Y resulta que quisiera que añadiera el número de página actual, el problema es que siempre me pone el mismo número, no incrementa.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Private Sub lbldibc_Click()
Dim rango As Range
Dim x As String
Set rango = ActiveDocument.Range(0, Selection.End)
x = rango.ComputeStatistics(wdStatisticPages)
LBLPIE.Caption = txtof1.Text & txtof2.Text & "-" & txtof3.Text & " " & TXTCLIENTE.Text & " " & TXTDIP.Text & " " & txtfd.Text & "/" & txtfm.Text & "/" & txtfa.Text & " " & cbotipo.Text & " " & "Esta es la pagina" & " " & x
LBLIR.Caption = txtof1.Text & txtof2.Text
lblrev.Caption = txtof3.Text
lblcliente.Caption = TXTCLIENTE.Text
lbltiporev.Caption = cbotipo.Text
lblrcpc.Caption = TXTRCP.Text
lbldibc.Caption = TXTDIP.Text
Selection.GoTo What:=wdGoToBookmark, Name:="tablita"
With ActiveDocument.Bookmarks
.DefaultSorting = wdSortByName
.ShowHidden = False
End With
Selection.Fields.Update
If cbotipo.Text = "TECHNICAL OFFER" Then LBLPIE.Caption = ""
Muchas gracias de antemano
Valora esta pregunta
0