View Single Post
 
Old 12-04-2019, 10:15 AM
mikejvir mikejvir is offline Windows 10 Office 2016
Novice
 
Join Date: Nov 2019
Posts: 10
mikejvir is on a distinguished road
Default

Point 3

I still have not found out how to alter all the margins in a table without using the double loop to step through every cell (that works). But on the slide I can do the following

Manually select the entire table on the slide.
Right click and select Format Shape.
Under the Size & Properties tab select Text Box.
Edit the margins and all the cells are modified (not just one).

There should be a way to the same operation via programming in VBA. If this is not possible I would like to know. Thanks.

To recap the other points

Point 1 - Reset the slide there are two solutions

Code:
Sub Reset_Slide()

Dim s As Slide

  Set s = ActivePresentation.Slides(ActiveWindow.View.Slide.SlideIndex)
  s.Select
  s.CustomLayout = ActivePresentation.Designs(1).SlideMaster.CustomLayouts(15)
  DoEvents
  Application.CommandBars.ExecuteMso ("SlideReset")
  DoEvents
End Sub
or

Code:
Sub Reset_Slide2()

Dim s As Slide

  Set s = ActivePresentation.Slides(ActiveWindow.View.Slide.SlideIndex)
  s.CustomLayout = s.CustomLayout

End Sub
Point 2 Table Reset

Code:
If oSh.HasTable Then
  Set oTbl = oSh.Table
  oTbl.ApplyStyle ("{5C22544A-7EE6-4342-B048-85BDC9FD1C3A}"), False
End If
Michael Virostko
Reply With Quote