porting extension [java-netbeans] from OpenOffice to LibreOffice

John D'Orazio john.dorazio at cappellaniauniroma3.org
Sun Sep 20 08:42:42 PDT 2015

Hello everyone, I wrote and published an extension for OpenOffice in Java
using the OpenOffice Netbeans plugin.

Now I am trying to port it over to LibreOffice so I can publish it as an
extension there too.

At first I was getting some errors such as this:

Exception in thread "AWT-EventQueue-0" java.lang.VerifyError: Stack map
does not match the one at exception handler 354 Exception Details:
 Location:     io/bibleget/BibleGetJSON.JSONParse(Ljava/lang/String;)V
@354: astore   Reason:     Type
'com/sun/star/lang/IllegalArgumentException' (current frame, stack[0]) is
not assignable to 'com/sun/star/uno/Exception' (stack map, stack[0])   Current
Frame:     bci: @283     flags: { }     locals: { 'io/biblege

But I think I figured out what the problem there was, it's not enough to
just change the context of the Netbeans plugin environment to LibreOffice 5
and LibreOffice 5 SDK, it's also necessary to actually create a new
OpenOffice plugin project after adjusting the context so that the right
.jar files will be included in the libraries.

However when I try to create a new OpenOffice project, after going through
the wizard I am getting this error: "unknown entity

So I don't know if the project is being created correctly or not...

I tried deleting all files in the project except the LibreOffice jar
libraries, and copying over all the files from the OpenOffice project
together with all other libraries that I am using (not OpenOffice jars).
However when I "build and install in OpenOffice", it does install the
extension to the extension manager and open LibreOffice, and I do see the
addon menu with the menu items, but all of the menu items are greyed out.

Does LibreOffice use a different .xcu format than OpenOffice? I'm guessing
it's not liking something in the

John R. D'Orazio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20150920/648b0edb/attachment.html>

More information about the LibreOffice mailing list