Avatar

Level 1
I'm new to Flex and web services. I've created a web service
in PeopleSoft and successfully imported the WSDL into Flex so that
it has contacted the PS server and returned data (using
mx:WebService and mx:Operation code I found examples of). However,
I have been unable to pass a parameter to the service from Flex
using that code. I then discovered and followed the sample code in
the Flex-generated package, but no matter what I do I cannot
successfully supply the "myValue" in the sample shown below. Here
is Flex's own text in my GetInfo.as file built by Flex:



* MXML sample code:

* First you need to map the package where the files were
generated to a namespace, usually on the <mx:Application>
tag, like this: xmlns:ws="com.draper.*"

* Define the service and within its tags set the request
wrapper for the desired operation

* <ws:GetInfo id="myService">

* <ws:FindID_request_var><ws:FindID_request
Find__CompIntfc__DL_TREE_IB_CI=myValue/>

* </ws:FindID_request_var>

* </ws:GetInfo>

* Then call the operation for which you have set the request
wrapper value above, like this:

* <mx:Button id="myButton" label="Call operation"
click="myService.FindID_send()" />





My code is:

<ws:GetInfo id="userRequest">

<ws:findID_request_var><ws:FindID_request
Find__CompIntfc__DL_TREE_IB_CI="X"/>

</ws:findID_request_var>

</ws:GetInfo>



When I try to run it, Flex is unhappy with the value I am
assigning ("X" above) no matter what I put there. If I omit the
double quotes and try to assign a text input field value (which is
my goal here), it complains that it expects a double quote. If I
put almost anything else there, it complains either:

Initializer for 'Find__CompIntfc__DL_TREE_IB_CI'; values of
type com.draper.Find__CompIntfc__DL_TREE_IB_CITypeShape cannot be
represented as text.

or, if I try this line, where I attempt to pass a text input
field:



<ws:FindID_request
Find__CompIntfc__DL_TREE_IB_CI="{compID.text}"/>



then I get:

1067: Implicit coercion of a value of type String to an
unrelated type com.draper:Find__CompIntfc__DL_TREE_IB_CITypeShape



Can anyone help with this please?



Thanks



Jim