Created
October 10, 2020 07:59
-
-
Save GroupDocsGists/e3a9ef77464fbb0818d81c79cdf18a06 to your computer and use it in GitHub Desktop.
Embed Document into Presentations as OLE Object in Java
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
// Embed Spreadsheet into a Presentations as an OLE object | |
int pageNumber = 1; | |
OlePresentationOptions oleSlidesOptions = new OlePresentationOptions("spreadsheet.xlsx", pageNumber); | |
// Set Coordinates and Dimensions | |
oleSlidesOptions.setX(10); | |
oleSlidesOptions.setY(10); | |
oleSlidesOptions.setHeight(200); | |
oleSlidesOptions.setWidth(200); | |
// Import the Spreadsheet into Presentation | |
Merger merger = new Merger("presentation.pptx"); | |
merger.importDocument(oleSlidesOptions); | |
merger.save("output-presentation.pptx"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment