openoffice-api mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg Schmidt <>
Subject reliably determine the location of soffice.exe
Date Sun, 15 Mar 2015 14:51:46 GMT

The following code returns the directory where soffice.exe is:

Sub Benutzerverzeichnis()
 aService = CreateUnoService("") 
 sUserPath = ConvertFromURL(aService.substituteVariables("$(prog)", true))
 InputBox ("Ihr aktuelles ist:", "Benutzerverzeichnis",
End Sub

Unfortunately, this does not always reliable, because under OOo 3.3.0 (Win7 32Bit) I get:

C:\Program Files\ 3\Basis\program

However, the soffice.exe is here:

C:\Program Files\ 3\program

How can I reliably determine the location of soffice.exe?

The above code works imho correctly for AOO 4.1.1 (only tested with a server-installation)
but I need a code that works for OOo 3.2.1 to AOO 4.1.1 (and, if it's possible, all LO-Versions).


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message