L
Lenny
Using Word 2003, I have set up a Protected/Unprotected Form Form(set)...The
file contains 5 different forms used by the engineering department. All of
the forms, with the exception of the first must be able to replicate
themselves. The forms are constructed using tables and section breaks as
required. At the bottom of each of the forms in the set is a paragraph mark
(set to 1.5 points). I am using the small routine (below) as part of the
macro to get to the bottom of each page, add a 'page break', and then insert
a specific table stored as an autotext entry to create another page in the
series. When I record the macro (gotobottom, insert break-page, autotext-add
table) the new page is there (bam!). All of the macros for this document are
stored in a toolbar for the engineers to use. When I run the macro from the
toolbar - the new page is all messed up. The page break is being added in
the table above, pushing the balance of the table to the next page along with
the addition of the autotext table and a space is added at the top of the
original table which also pushes the table further down..... I tried creating
a 'dummy' scenario in a blank document and when I initiate the gotobottom by
itself, it jumps to the cell marker (outside the table) at the last cell,
last row and not to a paragraph mark placed below the table, as I believe it
should. If I place two paragraph marks below the table, then the cursor does
jump to the first paragraph mark below the table.... can someone please
explain what may be happening and how I can correct to get the desired
results??? my thanks and best regards, Lenny
Sub GotoPgBottom()
Dim rTmp As Range
Set rTmp = Selection.Bookmarks("\page").Range
rTmp.End = rTmp.End - 1
rTmp.Collapse direction:=wdCollapseEnd
rTmp.Select
End Sub
file contains 5 different forms used by the engineering department. All of
the forms, with the exception of the first must be able to replicate
themselves. The forms are constructed using tables and section breaks as
required. At the bottom of each of the forms in the set is a paragraph mark
(set to 1.5 points). I am using the small routine (below) as part of the
macro to get to the bottom of each page, add a 'page break', and then insert
a specific table stored as an autotext entry to create another page in the
series. When I record the macro (gotobottom, insert break-page, autotext-add
table) the new page is there (bam!). All of the macros for this document are
stored in a toolbar for the engineers to use. When I run the macro from the
toolbar - the new page is all messed up. The page break is being added in
the table above, pushing the balance of the table to the next page along with
the addition of the autotext table and a space is added at the top of the
original table which also pushes the table further down..... I tried creating
a 'dummy' scenario in a blank document and when I initiate the gotobottom by
itself, it jumps to the cell marker (outside the table) at the last cell,
last row and not to a paragraph mark placed below the table, as I believe it
should. If I place two paragraph marks below the table, then the cursor does
jump to the first paragraph mark below the table.... can someone please
explain what may be happening and how I can correct to get the desired
results??? my thanks and best regards, Lenny
Sub GotoPgBottom()
Dim rTmp As Range
Set rTmp = Selection.Bookmarks("\page").Range
rTmp.End = rTmp.End - 1
rTmp.Collapse direction:=wdCollapseEnd
rTmp.Select
End Sub