Could anyone tell me how to access page styles in an OpenOffice text
document from a Visual Basic 6 application? I only succeed in opening
the document, but I do not get access to the styles collection (I want
to write text into the page headers):
Dim objServiceManager As Object
Dim objDesktop As Object
Dim objDocument As Object
Dim NoArgs() As Object
Set objServiceManager = CreateObject("com.sun.star.ServiceManager")
Set objDesktop = objServiceManager.createInstance_
("com.sun.star.frame.Desktop")
Set objDocument = objDesktop.loadComponentFromURL_
("file:///C:/aaa/test.sxw", "_blank", 0, NoArgs)
Dim Supplier
Dim Styles
Set Supplier = objServiceManager.createInstance_
("com.sun.star.style.XStyleFamiliesSupplier")
'now the code breaks:
Set Styles = Supplier.getStyleFamilies
Thanks in advance. Klaus Foerst from Flensburg, Germany
______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]