Hello all,


I found this macro that is able to hide rows using a toggle button.

I wanted to see if I could adapt it to hide columns.

I would like to hide at least columns 3 and 4

Private Sub ToggleButton1_Click()

With ActiveDocument.Tables(1).Rows(2)

'With ActiveDocument.Tables(1).Columns(2)

If .HeightRule = wdRowHeightExactly Then
.HeightRule = wdRowHeightAuto
.Borders(wdBorderBottom).LineStyle = wdLineStyleSingle
.Borders(wdBorderLeft).LineStyle = wdLineStyleSingle
.Borders(wdBorderRight).LineStyle = wdLineStyleSingle
Else
.HeightRule = wdRowHeightExactly
.Height = ".5"
.Borders(wdBorderBottom).LineStyle = wdLineStyleNone
.Borders(wdBorderLeft).LineStyle = wdLineStyleNone
.Borders(wdBorderRight).LineStyle = wdLineStyleNone
End If
End With
I have been researching column properties all morning - but I am unable to decipher and understand exactly the process above
as pertaining to columns.

any tips welcome

thank you

sam