Ariel Constenla-Haile wrote:
Hi Frank/Jürgen

Frank Schönheit - Sun Microsystems Germany escribió:
Which brings me to: Ariel, what do you mean with "initialize fails"? How
does this manifest?

In old-style services (like FilePicker), you instantiate the service in Basic by calling createUNOService("com.sun.star.ui.dialogs.OfficeFilePicker") and then you call initialize(Array(com.sun.star.ui.dialogs.TemplateDescription.FILESAVE_AUTOEXTENSION))

With a new-style service constructor, you can NOT call createUnoService() and then initialize() passing to this last call the constructor's parameters. In the example [1] initialize() "fails" == the object returned by createUnoService() has no such method, i.e. has already been initialized using the default constructor (I think :-( )
mmh, i don't know, have to check it in detail



And a new question: what diference makes (in Basic) if we use createInstanceWithArgumentsAndContext or just createInstanceWithArguments? In the example, both work the same.
yes, it still works but as mentioned before it's better to use the new methods because it's the newer and recommended way. If we would have enough time to change all places we would do that and we should deprecate the old interface.

Juergen



Bye and thanks,
Ariel.


[1] http://www.arielconstenlahaile.com.ar/ooo/temp/NEW_STYLE_SERVICE_CONSTRUCTOR_IN_BASIC.odt



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to