borders for tables in Word XP, doesn't work in Word 2007

D

Devon

Good morning

One of my jobs is to write procedure manuals. For previous versions of
Word, we created a template for blocks and subblocks. We could then save
these block and subblock tables in the autocorrect option, where when we
typed a few letters (blk or sblk), we would get the appropriate block or
subblock table to enter text. Hope this makes sense.

The process has been the same for numerous employees who have written an
unknown number of manuals. However, Office 2007 doesn't show the border
lines around the block and subblock tables.

I have created a new template for the manuals and for the block and subblock
I have added "All Borders" to the template, and then saved the tables in the
AutoCorrect feature as mentioned above. So going forward, everything should
be fine.

However, is there a way programmatically to update all the other documents
written in MS Word prior to Word 2007? I have manually udated a couple using
the "All Borders" option, but I know that there must be a faster way.

Thanks in advance for any assistance.
 
S

StevenM

To: Devon,

I'm unsure what "All Borders" means, but the following macro will change the
borders on all the tables in a document so that the have a single line
outside border and a single line inside border.

Sub UpdateTablesWithBorders()
Dim oTable As Table
For Each oTable In ActiveDocument.Range.Tables
With oTable.Borders
.Enable = True
.InsideLineStyle = wdLineStyleSingle
.OutsideLineStyle = wdLineStyleSingle
End With
Next oTable
End Sub

Steven Craig Miller
 

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