Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Embed Document into Word Document as OLE Object using Java
// Embed PDF into a Word Document as an OLE object
int pageNumber = 1;
OleWordProcessingOptions oleWordsOptions = new OleWordProcessingOptions("PDF-document.pdf", pageNumber);
oleWordsOptions.setWidth(200); // Setting the width and height of embedded document
// Import the PDF into Word Document
Merger merger = new Merger("document.docx"); // Source Word document
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.