Retrieve background pic

  • Thread starter Thread starter Edward
  • Start date Start date
E

Edward

IS it possible to retrieve background pic programatically ? after we insert a
pic in background ( slide or a cell) we don't have option to remove it we can
only replace it with another pic , I couldn't find any VBA method to access
to background pic and delete it. Am I right on my assumption that we can't
retrieve background pic?
 
As Steve says there's no direct way to get the pic in vba

This might work though (assumes pic is on slide 1)

Sub getbackground()
Dim osld As Slide
Dim i As Integer
ActivePresentation.Slides(1).Duplicate
Set osld = ActivePresentation.Slides(1)
For i = osld.Shapes.Count To 1 Step -1
osld.Shapes(i).Delete
Next i
osld.Export "Insert your Path to save.jpg", _
"jpg", ActivePresentation.PageSetup.SlideWidth, _
ActivePresentation.PageSetup.SlideHeight
osld.Delete
End Sub
 
Back
Top