Created
July 19, 2024 11:22
-
-
Save fileformat-slides-gists/88dcbc686337ab22c5d35e311e3e078c to your computer and use it in GitHub Desktop.
How to Remove Pictures from PowerPoint PPT PPTX Slides
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Presentation presentation = Presentation.Open("File_Path"); | |
// Get Slides | |
var slides = presentation.GetSlides(); | |
var slide = slides[1]; | |
// Get Images from slide | |
List<Image> images = slide.Images; | |
// Choose desired image | |
var image = slide.Images[0]; | |
// Remove image | |
image.Remove(); | |
// Save presentation | |
presentation.Save(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment