質問編集履歴
1
進展
title
CHANGED
File without changes
|
body
CHANGED
@@ -10,48 +10,39 @@
|
|
10
10
|
|
11
11
|
# 実行したコマンドとエラー
|
12
12
|
|
13
|
-
|
13
|
+
進展あり。
|
14
|
-
`Error: source file could not be loaded`
|
14
|
+
`Error: source file could not be loaded`は、LibreOfficeを一度起動し直すと何故か解消されました。
|
15
|
-
というエラーが発生します。
|
16
15
|
|
17
|
-
|
16
|
+
次のエラー。
|
18
17
|
|
19
|
-
**実行コマンド その1**
|
20
|
-
なおコマンドは、変換したいファイルがある場所まで`cd`してから実行しております。
|
21
|
-
|
22
|
-
```bash
|
23
|
-
/Applications/LibreOffice.app/Contents/MacOS/soffice --headless --nologo --nofirststartwizard --convert-to docx --outdir ./ test.pdf
|
24
|
-
```
|
25
|
-
|
26
|
-
|
27
18
|
---
|
28
19
|
|
29
|
-
|
20
|
+
以下の実行コマンドを叩きました。
|
30
21
|
|
31
22
|
```bash
|
32
|
-
/Applications/LibreOffice.app/Contents/MacOS/soffice --headless --
|
23
|
+
/Applications/LibreOffice.app/Contents/MacOS/soffice --headless --invisible --convert-to
|
24
|
+
docx:"MS Word 2007 XML" *.pdf
|
33
25
|
```
|
34
26
|
|
35
|
-
|
27
|
+
すると、以下のようなエラーがでます。
|
36
28
|
|
37
|
-
**実行コマンド その3**
|
38
|
-
|
39
29
|
```bash
|
40
|
-
/
|
30
|
+
convert /Users/USER_ID/project/test/test2.pdf -> /Users/USER_ID/project/test/test2.docx using filter : MS Word 2007 XML
|
31
|
+
Error: Please verify input parameters... (SfxBaseModel::impl_store <file:///Users/USER_ID/project/test/test2.docx> failed: 0xc10)
|
41
32
|
```
|
42
33
|
|
34
|
+
コンバートは開始できたが、引数の入力ができない?みたいなエラーですね。
|
35
|
+
(`Error: Please verify input parameters`)
|
43
36
|
|
44
|
-
|
37
|
+
ひとまず、`sudo`をつけて実行しましたが、同様のエラーになりました。
|
45
38
|
|
39
|
+
ちなみに、
|
40
|
+
`/Applications/LibreOffice.app/Contents/MacOS/soffice --headless --convert-to odg *.pdf`
|
46
|
-
|
41
|
+
だと問題なく変換されました。
|
47
42
|
|
48
|
-
```bash
|
49
|
-
/Applications/LibreOffice.app/Contents/MacOS/soffice --headless --nologo --nofirststartwizard --convert-to docx /User/から始まる絶対パス.pdf --outdir /User/から始まる絶対パス.docx
|
50
|
-
```
|
51
43
|
|
52
|
-
|
53
44
|
# 質問
|
54
|
-
なぜ、
|
45
|
+
なぜ、このようなエラーが発生するのでしょうか?
|
55
46
|
また、どのようにして解決すれば良いのでしょうか。
|
56
47
|
ご存じの方がいらっしゃいましたら、ご教示いただけますと幸いです。
|
57
48
|
|
@@ -60,6 +51,9 @@
|
|
60
51
|
- https://stackoverflow.com/questions/37772250/using-soffice-within-python-command-works-in-terminal-but-not-in-python-subproc
|
61
52
|
- https://qiita.com/knzm/items/4e58285c38196d994529
|
62
53
|
- https://qiita.com/y_irabu/items/5d916562744b05c5fc82
|
54
|
+
- http://d.hatena.ne.jp/kskmeuk/20170627/1498549844
|
55
|
+
- https://stackoverflow.com/questions/30349542/command-libreoffice-headless-convert-to-pdf-test-docx-outdir-pdf-is-not
|
56
|
+
- https://bugs.documentfoundation.org/show_bug.cgi?id=38511
|
63
57
|
|
64
58
|
|
65
59
|
---
|