Issue of permission denied in img2pdf #34

Closed
opened 2021-04-25 19:57:54 +00:00 by josch · 0 comments
Owner

By Leslie on 2017-06-28T09:14:03.865Z

Dear Sir,

Recently I just discovered your software img2pdf, I think it's very useful ,anf thank you for your hard work. However I've encountered a difficulty when try to convert a director of jpg files. The command line as below:

D:\Program\Office\PDF Tools>"D:\Program\Office\PDF Tools\img2pdf\build\lib\img2pdf.py" "D:\Program\Office\PDF Tools\file" -o out.pdf
usage: img2pdf.py [-h] [-v] [-V] [-o out] [-C colorspace] [-D]
[--without-pdfrw] [--first-frame-only] [-S LxL] [-s LxL]
[-b L[:L]] [-f FIT] [-a] [--title title] [--author author]
[--creator creator] [--producer producer]
[--creationdate creationdate] [--moddate moddate]
[--subject subject] [--keywords kw [kw ...]]
[--viewer-panes PANES] [--viewer-initial-page NUM]
[--viewer-magnification MAG] [--viewer-page-layout LAYOUT]
[--viewer-fit-window] [--viewer-center-window]
[--viewer-fullscreen]
[infile [infile ...]]
img2pdf.py: error: argument infile: "D:\Program\Office\PDF Tools\file" permission denied

I'm using Windows 10, 32 bit with Python 3.6. Hope you can help me on this issue. Thanks in advanced.

Regards,
Leslie Hui


By josch on 2017-06-28T11:38:43.613Z


Is D:\Program\Office\PDF Tools\file the path to the image that you want to convert?


By Leslie on 2017-06-28T16:37:24.053Z


Correct. I wish to convert all .jpg files inside the folder.


By josch on 2017-06-28T16:44:14.260Z


This is not how img2pdf works. You cannot give it the path to a folder but you have to give it the list of images that you want to convert into a pdf. That's what it means when it says in the error output above: [infile [infile ...]]. This is short for a list of input files. This is also what it says in the --help text.


By Leslie on 2017-06-28T17:45:56.424Z


Ok. I understood. Thanks for your help.


By Leslie on 2017-06-28T17:45:56.636Z


Status changed to closed

*By Leslie on 2017-06-28T09:14:03.865Z* Dear Sir, Recently I just discovered your software img2pdf, I think it's very useful ,anf thank you for your hard work. However I've encountered a difficulty when try to convert a director of jpg files. The command line as below: D:\Program\Office\PDF Tools>"D:\Program\Office\PDF Tools\img2pdf\build\lib\img2pdf.py" "D:\Program\Office\PDF Tools\file" -o out.pdf usage: img2pdf.py [-h] [-v] [-V] [-o out] [-C colorspace] [-D] [--without-pdfrw] [--first-frame-only] [-S LxL] [-s LxL] [-b L[:L]] [-f FIT] [-a] [--title title] [--author author] [--creator creator] [--producer producer] [--creationdate creationdate] [--moddate moddate] [--subject subject] [--keywords kw [kw ...]] [--viewer-panes PANES] [--viewer-initial-page NUM] [--viewer-magnification MAG] [--viewer-page-layout LAYOUT] [--viewer-fit-window] [--viewer-center-window] [--viewer-fullscreen] [infile [infile ...]] img2pdf.py: error: argument infile: "D:\Program\Office\PDF Tools\file" permission denied I'm using Windows 10, 32 bit with Python 3.6. Hope you can help me on this issue. Thanks in advanced. Regards, Leslie Hui --- *By josch on 2017-06-28T11:38:43.613Z* --- Is `D:\Program\Office\PDF Tools\file` the path to the image that you want to convert? --- *By Leslie on 2017-06-28T16:37:24.053Z* --- Correct. I wish to convert all .jpg files inside the folder. --- *By josch on 2017-06-28T16:44:14.260Z* --- This is not how img2pdf works. You cannot give it the path to a folder but you have to give it the list of images that you want to convert into a pdf. That's what it means when it says in the error output above: `[infile [infile ...]]`. This is short for a list of input files. This is also what it says in the `--help` text. --- *By Leslie on 2017-06-28T17:45:56.424Z* --- Ok. I understood. Thanks for your help. --- *By Leslie on 2017-06-28T17:45:56.636Z* --- Status changed to closed
josch closed this issue 2021-04-25 19:57:54 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: josch/img2pdf#34
No description provided.