Questions tagged [docx2pdf]
19 questions
3
votes
1 answer
How to add doc2pdf to custom docker container
I want to use doc2pdf program in my python:3.9-slim-bullseye container
I added libreoffice-writer unoconv to my container
Dockerfile
FROM python:3.9-slim-bullseye
WORKDIR /project
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONBUFFERED=1
COPY . .
RUN…

mascai
- 1,373
- 1
- 9
- 30
2
votes
1 answer
Problem when trying to convert .docx files to .pdf
I'm trying to create a simple docx to pdf converter and it throws me this problem:
Exception has occurred: com_error
(-2147352567, 'Exception occurred.', (0, 'Microsoft Word', 'Sorry, we couldn’t find your file. Is it possible it was moved, renamed…

Chris 789
- 41
- 1
2
votes
2 answers
Converting docx.files to pdf.files with docx2pdf
Not sure what I am doing wrong.
I want to convert multiple docx.files to pdf.files - each file into a separate one.
I decided to use the "doconv"-package with following command:
docx_files <-…

Nadiine El Nino
- 339
- 1
- 6
1
vote
1 answer
Base64 Docx to Base64 pdf
Im trying to convert a Base64 Docx to a Base64 pdf, for test purpose im receiving the base64 docx and im saving it in my Django static folder like this:
Proyect
--App
----static
------Docs
--------test.docx
So, Im trying with doxc2pdf library to…

jsanchezs
- 1,992
- 3
- 25
- 51
0
votes
1 answer
docx2pdf close all the other word files that are opened
I am currently using the docx2pdf library in Python to convert Word files to PDF format. However, I have noticed that when I execute the conversion process, it forcibly closes all other Word files that I may have open for editing. Is there a way to…

TariqShah
- 25
- 7
0
votes
0 answers
Docx2pdf Access is denied on Windows 2022 server (Flask)
When hosting Flask app on Windows 2022 server with 64bit Python, using libraries flask, docxtpl and docx2pdf, I am getting and error
pywintypes.com_error: (-2147024891, 'Access is denied.', None, None)
It looks like that the Flask app can't access…

Matej Zupan
- 11
- 2
0
votes
0 answers
0% | 0/1 [00:00, ?it/s] error while building docx to pdf converter using docx2pdf python package
I am using Mac and trying to build a converter that converts docx file to pdf file. I am using docx2pdf python package.
from docx2pdf import convert
convert('my.docx')
When I run the code, I am getting " 0%| | 0/1 [00:00, ?it/s]"…

David David
- 21
- 4
0
votes
0 answers
How to convert docx to pdf in python dash
I am trying to deploy a python dash app to Heroku server. I perform some calculations based on user input and I create a docx report (I have a specific .docx template and I fill it with data each time). My problem is that before sending that report…
0
votes
0 answers
com_error: When converting docx to pdf in python
I am currently trying to convert some word documents to PDF using python, some of the files converted successfully with the code I have while I got the following error messages on other files:
Error 1: some files reported
com_error: (-2147352567,…

tee
- 11
- 1
0
votes
0 answers
How to print a word doc to pdf without markups using python
So sometimes at my job we have to change the date in the header of dozens of word docs and print to pdf. This is such a pain and so I wrote the python code provided to go through and change text and print for me. However, the word docs have markups…
0
votes
1 answer
Q: (docx2pdf) using python
I use python to write code to convert docx to pdf, but I get this error:
On Windows: pywintypes.com_error: (-2147352567, 'Exception occurred.', (0, 'Microsoft Word', 'Command failed', 'C:\Program Files (x86)\Microsoft Office\Office12\…

Vuvanvui Vui
- 9
- 1
0
votes
0 answers
how to do docx to pdf conversion using python library without subprocess in linux?
I tried this docx2pdf library in windows.but in linux I'm facing the error as
NotImplementedError: docx2pdf is not implemented for linux as it requires Microsoft Word to be installed
any alternative library to convert docx to pdf using python…

Lokeshwar G
- 136
- 6
0
votes
0 answers
How to make docx2pdf work on Google Colab to convert Docx to PDF automatically
I am getting following error when I tried to convert docx to PDF using docx2pdf imported from docx
Google colab code:
!pip install docx2pdf
from docx2pdf import convert as doc2pdf
doc2pdf('My_document.docx')
Present output:
docx2pdf is not…

Mainland
- 4,110
- 3
- 25
- 56
0
votes
0 answers
Can python-docx and docx2pdf work on android in a KivyMD apk?
I wanted to develop an apk using Python and its KivyMD module.
The program used python-docx to retrieve and modify data in a word file and then save it.
Also it used docx2pdf to convert the word file to a pdf file. On my computer the program worked…
0
votes
1 answer
FileNotFound Error while converting docx2pdf
im trying to make a python program that converts docx files to pdf using flask. But i get an Error like this:
Below I paste code:
from flask import Flask
from flask import request, render_template, send_file
import os
from typing import Tuple
from…

Mixhalo
- 33
- 1
- 5