This content has been marked as final. Show 12 replies
You should be getting a RunScriptResult in the returned XML packet. Something like...
words in story = 3
This is what I'm getting:<br /><br /><?xml version="1.0".encoding="UTF-8"?><br /><SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance" xmlns:xsd="http://www.w3.org/1999/XMLSchema" xmlns:IDSP="http://ns.adobe.com/InDesign/soap/"><br /> <SOAP-ENV:Body><br /> <IDSP:RunScriptResult><br /> <errorNumber><br /> 0<br /> </errorNumber><br /> <scriptResult><br /> </scriptResult><br /> </IDSP:RunScriptResult><br /> </SOAP-ENV:Body><br /></SOAP-ENV:Envelope><br /><br />I would like to get actual data returned. On the other InDesign forum it was stated that IDS would return the last command in the script. however I have not seen anything other than the error number returned.
app.consoleout = "words in story = "+theCount;
.. will return the result I show above.
After making a bad js file I realize that it's my axis that for some reason is either not deserializing or receiving the response IDS is sending stuff back but I can't see it.
For some reason, app.consoleout didn't work for me but I figured out an alternative.
Wrap the code in a function and have the function return a value. Then call that function. Here's an example.
app.consoleout("SOAP test started!");
app.consoleout("SOAP test finished!");
You should see, "MY-RETURN-VALUE" in scriptResult.data.
we have here exactly the problem, that tom described. the return value arrives correctly on the network interface (checked with a packet sniffer) within the following soap message:
but the problem is now, that this value can't be read from the java application. if i debug the code, i receive the errorNumber but the scriptResult --> data is alway NULL?
does anybody have an idea?
There is a sample client in the InDesign CS3 Server SDK that demonstrates how to interact with InDesign Server through SOAP via Java, using Apache Axis 1.2.1. It's in the samples/sampleclient-java-soap folder.
Basically, Axis is used to generate the SOAP wrapper. One of the classes it creates is DataHolder. When runScript returns, the DataHolder object will hold the return value which can be accessed from the "value" field: myDataHolder.value.getData()
* As above, return a value from the main method, and make sure main is the last function you call:
* Access the return value in the last statement in the script:
var theStrokeWeight = myRectangle.strokeWeight;
// ... do more stuff ...
I Have Prepared a Client Which Attaches & sends XML file To Web Service,
I Got Exception:exception occuredjava.io.FileNotFoundException: http://184.108.40.206:8080/soap/desiya/TestWebsevice/message209
Wld U Pls Help me To Solve This Error.
I have some problem reading response from IDS.
I use Flex 3.0 and actionscript.
I run a js and it works correctly.
The script ends with app.consoleout command and I can see the result in the terminal but I can not read the response in "scriptResult.data".
Flex debugger tell me "data" is not defined.
I try to read the response from RunScriptResponse, from scriptResult and also from event.result but without success.
Is it possible that the problem is in the WSDL file?
Can you help me?
var myReturnData = "hello there";
// ... more stuff here
Is it possible to read from the terminal also during the execution of a script, or only at the end?
I would like to trace the progress of my scripts and show a progress bar.