Hi Mikhail,
Here is the code snippet I converted, it runs well but I could not
observe the thrown exceptions. Should there be a window or a dialog to
show the exceptions?
Best Regards,
Felix.
REM ***** BASIC *****
Sub Main
Dim objMy As Object
objMy = createHiddenDocument()
objmy.dispose()
End Sub
Function createHiddenDocument() As Object
'Try to create a hidden document
Dim objPropValue As New com.sun.star.beans.PropertyValue
'Set the members. If this fails then there is an Error
objPropValue.Name = "hidden"
objPropValue.Handle = -1
objPropValue.Value = True
'create a hidden document
'Create the Desktop
Dim objDesktop As Object
objDesktop = createUnoService("com.sun.star.frame.Desktop")
'Open a new empty writer document
Dim args(0) As Object
args(0) = objPropValue
createHiddenDocument =
objDesktop.loadComponentFromURL("private:factory/swriter", "_blank", 0,
args)
End Function
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@framework.openoffice.org
For additional commands, e-mail: dev-h...@framework.openoffice.org