Page 1 of 1

[Solved] First C++ Add-in on Mac OS X

Posted: Mon Jul 02, 2012 5:14 pm
by saleem145
Hello,

I am playing with

http://wiki.services.openoffice.org/wik ... alc_Add-In

I have it compiling.

As per instructions I have placed

RNG.rdb and libRNG.dylib

in

/Applications/OpenOffice.org.app/Contents/program

And edited fundamentalrc. The last two lines are

URE_MORE_SERVICES=${${OOO_BASE_DIR}/program/fundamentalbasisrc:URE_MORE_SERVICES} $ORIGIN/services.rdb $ORIGIN/RNG.rdb
URE_MORE_TYPES=${${OOO_BASE_DIR}/program/fundamentalbasisrc:URE_MORE_TYPES} $ORIGIN/RNG.rdb

I have edited the main macro

Sub Main

mgr = getProcessServiceManager()
o = mgr.createInstance("org.openoffice.sheet.addin.RNG")
MsgBox o.expo(10)

End Sub

However when I run it I get the message "Basic Runtime Error", "Object Value not set". o is set to NULL.

Which means I have not installed the add-in correctly.

Any suggestions??

Saleem

Re: First C++ Add-in on Mac OS X

Posted: Mon Jul 02, 2012 8:18 pm
by saleem145
I now have the following error --

BASIC runtime error.
An exception occurred/
Type: com.sun.star.loader.CannotActivateFactoryException
Message: loading component library failed: libRNG.dylib

The question is how to debug this further -- how do I know it is looking in the folder where it is present?? How do check if the library file is correct