To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=71676
Issue #|71676
Summary|ScriptProvider.getScript failed
Component|scripting
Version|OOo 2.0.2
Platform|PC
URL|
OS/Version|Linux
Status|NEW
Status whiteboard|
Keywords|
Resolution|
Issue type|DEFECT
Priority|P5
Subcomponent|code
Assigned to|kr
Reported by|coplo
------- Additional comments from [EMAIL PROTECTED] Fri Nov 17 13:28:36 -0800
2006 -------
It is not possible to get a script (with its correct URI) from the
ScriptProvider-Object. Therefore you can not run macros with Script-Object.
OOo 2.0.2
Browse with the BrowseNodeFactory for a script.
Get the URI from the node.
Get the script from ScriptProvider-Object.
You get "Basic Runtime-Error BasicProviderImpl::getScript: no script!."
Sub test()
dim oBNF, oBN, oSP, oS as Object
dim aBN() as Object
dim vURI as variant
oBNF =
createUnoService("com.sun.star.script.browse.BrowseNodeFactory")
oSP =
createUnoService("com.sun.star.script.provider.ScriptProviderForBasic")
oBN = oBNF.createView(0)
aBN = oBN.getChildNodes()
oBN = aBN(xyz) 'node user
aBN = oBN.getChildNodes()
oBN = aBN(xyz) 'node module
aBN = oBN.getChildNodes()
oBN = aBN(xyz) 'node function
vURI = oBN.getPropertyValue("URI")
oS = oSP.getScript(vURI)
' oS = oSP.getScript("vnd.sun.star.script:module.function?
' language=Basic&location=application")
end sub
---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]