soffice --params in Windows cli does nothing

asked 2018-11-04 08:41:52 +0100

joey33 gravatar image

updated 2018-11-04 16:05:25 +0100

EasyTrieve gravatar image

Hello, after unsuccessul efforts to batch convert files I've tried running a simple 'soffice --help' but it does nothing. I checked background processes - no other instances of soffice/libreoffice are launched. Running just 'soffice' with no params launches the application correctly. I've run out of ideas. I'm on Win7 64bit and using 64bit version of LO.

image description

edit retag flag offensive close merge delete

Comments

This is a bug affecting some Windows versions. To workaround it and see the output, please put the command to a link (shortcut file, .LNK), then it will open up a dedicated console for the output with "press any key to continue".

Mike Kaganski gravatar imageMike Kaganski ( 2018-11-04 08:59:08 +0100 )edit

Thx Mike. Could you give me a hint of the contents of the .lnk file? I put 'c:\Program Files\LibreOffice\soffice --help' in test.lnk then I tried clicking it, launching it from cmd. I tried putting 'run' before the path - to no avail. Guess it requires special format/commands?

joey33 gravatar imagejoey33 ( 2018-11-04 09:40:01 +0100 )edit

Don't forget to put the path with spaces into doublequotes, like

"C:\Program Files\LibreOffice\program\soffice.exe" --help

and don't launch it from cmd - just double-click it

Mike Kaganski gravatar imageMike Kaganski ( 2018-11-04 10:00:21 +0100 )edit

The contents of my test.lnk file:

"C:\Program Files\LibreOffice\program\soffice.exe" --help

I placed the file on the desktop. Double-clicking the icon does nothing, double-clicking in TotalCmd shows "Error executing program! (31)".

joey33 gravatar imagejoey33 ( 2018-11-04 10:10:40 +0100 )edit

Could you please try running the command when you have LO already running in normal GUI mode?

Mike Kaganski gravatar imageMike Kaganski ( 2018-11-04 10:18:12 +0100 )edit

Actually I was going to tell you before that when LO GUI is launched in the back, running

soffice --help

in LO/program folder works but it opens another cli window. I took this as abnormal operation because I still couldn't make --convert-to work and I read in forums that any LO processes must be closed. Coming back to .lnk file - with LO GUI launched now in the back, clicking 'test.lnk' still does nothing.

joey33 gravatar imagejoey33 ( 2018-11-04 10:38:02 +0100 )edit

Well - as I told you, that is a bug. Unfortunately, I didn't have an opportunity to handle it properly yet. The only reliable workaround is using cygwin (and then not forget to use forward slashes instead of backslashes). Also, possibly you could post a command line to discuss.

Mike Kaganski gravatar imageMike Kaganski ( 2018-11-04 10:41:00 +0100 )edit

Ok I made --convert-to work, though to limited extent. Looks like I needed to specify --outdir (read it was optional and when not specified, files would be saved to src folder) and cannot use *.odt wildcard to convert all files in src folder. One by one works (with/without LO GUI in the back).

joey33 gravatar imagejoey33 ( 2018-11-04 10:43:09 +0100 )edit

Thx Mike for your efforts:)

joey33 gravatar imagejoey33 ( 2018-11-04 10:44:59 +0100 )edit