I've created a code that copies pictures from Excel to a new PowerPoint presentation. The code works fine for MS Office 2016, but not MS Office 2010. Particularly, a picture that is exported to PowerPoint will not be resized in .pptx
for 2010.
How can I fix this?
Here is the problematic piece of code that does not work in MS 2010:
Application.Goto Reference:="Full_Account_Performance"
Application.CutCopyMode = False
Selection.CopyPicture Appearance:=xlScreen, Format:=xlPicture
PPPres.Slides(x).Shapes.PasteSpecial
On Error Resume Next
With PPApp.ActiveWindow.Selection.ShapeRange
.ScaleHeight 0.435, msoFalse, msoScaleFromTopLeft
'Powerpoint 2010 ingnors it... but in 2016 it is fine
.Left = 10
.Top = 55
End With