Created
December 7, 2024 06:42
-
-
Save documentprocessing/023f249460f46acf453c117c7e519a38 to your computer and use it in GitHub Desktop.
Add Image in a Slide in .NET
This file contains hidden or 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.Create("InsertImageInSlide.pptx"); | |
// Create slide | |
Slide slide = new Slide(); | |
// Add text shapes. | |
Image image1 = new Image("image.png"); | |
// Set xAxis | |
image1.X = 180.0; | |
// Set yAxis | |
image1.Y = 128.0; | |
// Set Width | |
image1.Width = 195.0; | |
// Set Height | |
image1.Height = 55.0; | |
// Add image to slide | |
slide.AddImage(image1); | |
// Adding slides | |
presentation.AppendSlide(slide); | |
// Save presentation | |
presentation.Save(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment