I work with Excel workbooks on my
MacBook Pro
laptop that have embedded
PowerPoint
slides on some worksheets. The workbooks, which I need to review, are
created by others. When I review them, I
extract information from
the Excel workbooks to an SQLite database with Python and also have begun
extracting information embedded by
Object Linking and Embedding (OLE) into files as
noted in Extracting the
contents of a directory in a zipfile using Python. Some of the
embedded files are PowerPoint files, but when they are extracted they
have a .bin extension, which I can't open in
PowerPoint without changing the
filename extension from .bin to .ppt. To automate the renaming process,
I created a Python script, extract_embedded.py
that will extract
the embedded information to files in an "embedded" directory beneath the
current working directory and then rename any .bin files that are PowerPoint
files to have a .ppt extension. The script is shown below.
[ More Info ]