Unable to remove excess white space above and below text in Word table cells

I have a Word document with a large table in it. My problem is that the height of the cells is too great. The pages contain lots of white space above and below the text in the cells. Since the document is 30 pages long, it would be great to reduce that if at all possible. I've looked at lots of options, e.g. Table Properties --> Options -->Set Default cell margins to 0, Paragraph properties and Layout --> Spacing -->Set Spacing before and after to 0pt, but none of those seem to help.

The Word document itself is generated from Microsoft Access VBA, but that shouldn't affect anything (should it???). An example is available at https://www.dropbox.com/s/za6ephjziir1lkx/Example%20table%20problem.docx?dl=0 if anyone would like to give it a go.

Many thanks,

Alan

Answer
Answer

The cells have top and bottom margins of 0.16"

Image

As those margin settings are not that same as that set for the Table itself, it's a bit tedious to access each cell individually as is necessary to change the cell margins, so if you run a macro containing the following code

With Selection.Tables(1)

    For i = 1 To .Rows.Count

        For j = 1 To .Columns.Count

            With .Cell(i, j)

                .BottomPadding = 0

                .TopPadding = 0

            End With

        Next j

    Next i

End With

The table will be changed to:

Image

Hope this helps,
Doug Robbins - MVP Office Apps & Services (Word)
dougrobbinsmvp@gmail.com

14 people found this reply helpful

·

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

 
 

Question Info


Last updated April 22, 2025 Views 26,686 Applies to: