You are here

Portable Libreoffice and Libreoffice UNO SDK C++

6 posts / 0 new
Last post
davidgraywright
Offline
Last seen: 10 years 5 months ago
Joined: 2014-06-29 18:35
Portable Libreoffice and Libreoffice UNO SDK C++

Does anyone know if these two work together on Windows?

I have written a program that works against the full version but our clients have Libre Office Portable installed and I am failing to get my program connected to Portable LibreOffice. I am getting a NoConnectException. Before I dig down any further I would like to know If I should try based on whether they do work or not? I have seem many questions about it not working on the Portable Libre Office website.

John T. Haller
John T. Haller's picture
Online
Last seen: 36 min 36 sec ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Registered Component?

Does it use a component that is registered with Windows (aka in the Windows registry or local file system)? If so, then it will not work with the portable version. With portable software, you can only access the components directly by their file path or via API calls while they are already running.

Sometimes, the impossible can become possible, if you're awesome!

davidgraywright
Offline
Last seen: 10 years 5 months ago
Joined: 2014-06-29 18:35
SDK throws a NoConnectException

That's what I'd like to know I suppose. My program does not use the registry at all. My program starts the soffice executable via the bootstrap function but cannot communicate to the running program - in the IDE I see the SDK throws a NoConnectException.
UNO exception: Connector : couldn't connect to socket (WSANOTINITIALISED, WSAStartup() has not been called)

davidgraywright
Offline
Last seen: 10 years 5 months ago
Joined: 2014-06-29 18:35
Yes - Success

The LibreOffice UNO C++ SDK does work with Portable LibreOffice.

Wm ...
Offline
Last seen: 7 years 11 months ago
Joined: 2010-07-17 12:37
anything to note in case someone comes up against this again?

anything to note in case someone comes up against this again?

Wm

davidgraywright
Offline
Last seen: 10 years 5 months ago
Joined: 2014-06-29 18:35
The Long story of how it works...

I wrote a program for the MAC that worked with the Full Version and then went to Windows and tried to compile the same program for LibreOffice Portable and it just failed opening and saving the files. However I could tell the UNO bridge was partially working (I could send the text in the file via the C++ bridge to an open blank writer document).

I then created a Virtual Machine installed the full LibreOffice and my program still did not work - same exceptions. So I looked inside my program. I was prepending "file://" instead of "file:///" to the full path of the file being converted and I also changed to Unix style paths so - '\\' became '/' in my program.

I hope this helps someone in the future.

Log in or register to post comments