Hi Bernard,
please find my comments inline:
This is a rewriting of a message posted on [email protected]
I did not get any answer, so I try again on UDK mailing list.
There are two problems on this subject.
First problem : I want to call a script (Basic, Python...) from the
command line, using the method introduced with OpenOffice.org 2.0.
Example with Python, calling a script without arguments:
soffice.exe
"vnd.sun.star.script:MyScriptFile.py$myRoutine?language=Python&location=user"
If my script is declared as having one optional argument, I find in the
called script that this argument is not empty, but contains the value True.
This happens both with a Python or a Basic script.
Is this normal? Is my syntax incorrect ?
I will have a look. For now I don't have an idea why
this should happen.
Second problem : is it possible to provide arguments to a script called
from the command line ? (trying to guess the syntax led to the first
problem)
Sorry, but as described in the Developers Guide, chapter
"18.6.1 Scripting Framework URI specification" the script
URI does not support parameters. In general this would
not make much sense anyway as the URIs are usually used
for binding (control) events to scripts and parameters
do not exist there.
In your case parameters obviously would make sense, but
also the macro dispatcher doesn't support them as far as
I know. The only way you can go is to use different en-
try macros for different situations, e.g.
"vnd.sun.star.script:MyScriptFile.py$startHidden?language=Python&location=user"
"vnd.sun.star.script:MyScriptFile.py$startNormal?language=Python&location=user"
but of course this is only possible, if you don't want
to pass parameters with a big range of possible values.
Regards
Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]