How do I retrieve the LO version with a macro

Have have a need to retrieve the LO version number with a macro
(I want to log it along with Error numbers for debugging purposes)

I think perhaps the Base variable “version” holds the info.
At least it does sometimes …
I have the same LO app with the same version of LO running on an iMac & a macbook pro
the former
print Version
yeilds

“LibreOffice 4.4.3.2”

the latter causes a weird form error #380 at line AllForms I’m trying to put the text into
a text box on an About form for the application in both instances

Both machines are running OSX 10.10.3

tTo repeat both are running the SAME LO app withe SAME code ???

Hi - You can use

sub FindBuildID
dim oService as object
oService = CreateUnoService("com.sun.star.sheet.FunctionAccess")
msgbox oService.callFunction("INFO", array( "version"))    
end sub

Or

sub FindVersion()

dim kc as object

globalScope.basicLibraries.loadLibrary("Tools")

kc = getRegistryKeyContent("/org.openoffice.Setup/Product", false)

msgbox kc.ooSetupVersionAboutBox
'msgbox kc.ooName' 
'msgbox kc.ooSetupVersion'

end sub

Thank you.