StarPig
02-17-2023, 05:16 AM
Hi Andy / John
I've been trying to write code to remove only the 4 outside borders of any table that's selected. I found this closest code by Andy (after hours of googling and editing codes I've found online), but it's from 2006 and no longer works:
http://www.vbaexpress.com/forum/showthread.php?8751-Solved-Removing-a-table-s-Outline-border
Any help would be much appreciated, as always, thank you.
Dim tblTemp As Table
Set tblTemp = ActivePresentation.Slides(1).Shapes(3).Table
With tblTemp
.Rows(1).Cells.Borders.Item(ppBorderTop).Visible = msoFalse
.Rows(.Rows.Count).Cells.Borders.Item(ppBorderBottom).Visible = msoFalse
.Columns(1).Cells.Borders.Item(ppBorderLeft).Visible = msoFalse
.Columns(.Columns.Count).Cells.Borders.Item(ppBorderRight).Visible = msoFalse
End With
It's just to remove (or make white to hide) the outside borders of any table, no matter how many rows or columns it has, no existing inside borders are changed.
Thank you
I've been trying to write code to remove only the 4 outside borders of any table that's selected. I found this closest code by Andy (after hours of googling and editing codes I've found online), but it's from 2006 and no longer works:
http://www.vbaexpress.com/forum/showthread.php?8751-Solved-Removing-a-table-s-Outline-border
Any help would be much appreciated, as always, thank you.
Dim tblTemp As Table
Set tblTemp = ActivePresentation.Slides(1).Shapes(3).Table
With tblTemp
.Rows(1).Cells.Borders.Item(ppBorderTop).Visible = msoFalse
.Rows(.Rows.Count).Cells.Borders.Item(ppBorderBottom).Visible = msoFalse
.Columns(1).Cells.Borders.Item(ppBorderLeft).Visible = msoFalse
.Columns(.Columns.Count).Cells.Borders.Item(ppBorderRight).Visible = msoFalse
End With
It's just to remove (or make white to hide) the outside borders of any table, no matter how many rows or columns it has, no existing inside borders are changed.
Thank you