Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add different file formats for doc type #3

Open
e-caste opened this issue Aug 16, 2020 · 1 comment
Open

Add different file formats for doc type #3

e-caste opened this issue Aug 16, 2020 · 1 comment
Assignees
Labels
backend the logic enhancement New feature or request
Milestone

Comments

@e-caste
Copy link
Owner

e-caste commented Aug 16, 2020

Other than .pdf, add .pptx, .ppt, .doc, .docx, etc...

@e-caste e-caste added the enhancement New feature or request label Aug 16, 2020
@e-caste e-caste self-assigned this Aug 16, 2020
@e-caste e-caste added the backend the logic label Aug 18, 2020
@e-caste e-caste added this to the 2.3.0 milestone Feb 15, 2021
@e-caste
Copy link
Owner Author

e-caste commented Apr 26, 2022

For .pptx python-pptx seems the best choice, but it fails to open any older .ppt file. Luckily it looks like these guys have worked it out quite well for .ppt files.

Example of working code on Windows:

import aspose.slides as slides
import os

def print_number_of_slides_with_aspose_slides(file_name):
    prs = slides.Presentation(file_name)
    print(f"Presentation '{file_name}' has {len(prs.slides)} slides.")


for file in os.listdir("ppt"):
    print_number_of_slides_with_aspose_slides(os.path.join("ppt", file))

The issue here is that at https://docs.aspose.com/slides/python-net/features-overview/ we read:

The platforms Aspose.Slides for Python via .NET can be used on Windows x64 or x86 and wide range of Linux distributions with Python 3.5 or later installed.

so no macOS support (pip outputs ERR: Could not find a version that satisfies the requirement aspose.slides (from versions: none)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend the logic enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant