Extract embedded images from a word document.Extract embedded images from a libreoffice document.
Extract images from a document.
Many times the question occurs to us that they send us a .doc document of word or one of libreoffice .odt with the images embedded in it. We need to extract images from a document and the task that we have to do is to save the images one by one without the possibility of extracting them all at once. This is a very tedious task, well, something so cumbersome is sometimes very easy to solve, just:
-
Extract embedded images from a word document.
The easiest way to extract the images is:
- Access the «save as» menu and store the document as a web page.
- We keep in a folder that we want
- Automatically we will generate a document .html with the name that we have given.
- Also a folder with the images that contain the word document embedded.
So in this simple way we already have the document images to use them in whatever we need. Maybe you're thinking, but since it had not occurred to me before. What nonsense, well, yes, it had not occurred to me either, and it has looked silly when I read it.
-
Extract embedded images from a libreoffice document.
In this case the save as html does not work because it embeds the images in binary format. It stores everything as an html document that therefore has a very large size. In my case it was stored in a size of about 7 megabytes, something complicated to handle and the images are stored embedded in it. In the case of libreoffice writer, to obtain the images in a simple way it is necessary to do it in the following way:
- we save the document with .odt extension.
- we access the route where it was stored.
- we change the odt extension to a .zip extension.
- We open the .zip file.
- and there it is, this compressed file contains many files with styles, css and a folder with images (if they are similar or many it is complicated to manage because they have a more or less equal name) that contains all the images of the libreoffice document.