Difference between revisions of "Calc/Add-In/CompleteAddIn"

From Apache OpenOffice Wiki
< Calc‎ | Add-In
Jump to: navigation, search
(The code)
(IDL File)
Line 9: Line 9:
 
Here is the corresponding IDL file :
 
Here is the corresponding IDL file :
 
<pre><nowiki>
 
<pre><nowiki>
 +
// IDL
 
#include <com/sun/star/uno/XInterface.idl>
 
#include <com/sun/star/uno/XInterface.idl>
 
#include <com/sun/star/lang/XInitialization.idl>
 
#include <com/sun/star/lang/XInitialization.idl>
Line 18: Line 19:
 
interface XSomething : com::sun::star::uno::XInterface
 
interface XSomething : com::sun::star::uno::XInterface
 
{
 
{
  string methodOne( [in] string val );
+
string methodOne( [in] string val );
  string methodTwo( [in] string val );
+
string methodTwo( [in] string val );
 +
long methodThree( [in] sequence< sequence< long > > aValList );
 +
sequence< sequence< long > > methodFour( [in] sequence< sequence< long > > aValList );
 
};
 
};
 
service MyService2
 
service MyService2
 
{
 
{
    interface XSomething;
+
interface XSomething;
    interface com::sun::star::lang::XInitialization;
+
interface com::sun::star::lang::XInitialization;
    interface com::sun::star::lang::XServiceName;
+
interface com::sun::star::lang::XServiceName;
    interface com::sun::star::sheet::XAddIn;
+
interface com::sun::star::sheet::XAddIn;
 +
};
 
};
 
};
};
 
 
</nowiki></pre>
 
</nowiki></pre>
  
 
==The code==
 
==The code==

Revision as of 15:45, 17 April 2006

We start from an example of SDK slightly modified :

<OpenOffice.org1.1_SDK>/examples/DevelopersGuide/Components/CppComponent

This example contains two files but I only use one file (and one service).

IDL File

Here is the corresponding IDL file :

// IDL
#include <com/sun/star/uno/XInterface.idl>
#include <com/sun/star/lang/XInitialization.idl>
#include <com/sun/star/lang/XServiceName.idl>
#include <com/sun/star/lang/XLocalizable.idl>
#include <com/sun/star/sheet/XAddIn.idl>
module my_module
{
interface XSomething : com::sun::star::uno::XInterface
{
string methodOne( [in] string val );
string methodTwo( [in] string val );
long methodThree( [in] sequence< sequence< long > > aValList );
sequence< sequence< long > > methodFour( [in] sequence< sequence< long > > aValList );
};
service MyService2
{
interface XSomething;
interface com::sun::star::lang::XInitialization;
interface com::sun::star::lang::XServiceName;
interface com::sun::star::sheet::XAddIn;
};
};

The code

Personal tools