Dynamic HTTPService request AS3

I'm doing a mashup in Flex right now using Yahoo Maps. One of
the functions allows users to create their own routes.
Here's the problem. I need a dynamic httpService request
because I never know beforehand how many markers a route holds.
Here's my code:
[Bindable]
private var rssFeed:String;
private function opslaanRoute(event:Event):void
if(this.tekstInputVenster.text!="")
if(markerLijst.length>0)
rssFeed = "<route>";
rssFeed +=
"<routebeschrijving>"+this.tekstInputVenster.text+"</routebeschrijving>";
var lengte:Number = markerLijst.length;
for(var d:Number=0;d<lengte;d++)
rssFeed +="<marker>";
rssFeed +=
"<latlon"+d+">"+markerLijst[d][0]+"</latlon"+d+">";
rssFeed +=
"<indexMarker"+d+">"+markerLijst[d][1]+"</indexMarker"+d+">";
rssFeed +=
"<titel"+d+">"+markerLijst[d][2]+"</titel"+d+">";
rssFeed +=
"<beschrijving"+d+">"+markerLijst[d][3]+"</beschrijving"+d+">";
rssFeed +="</marker>";
rssFeed += "<aantal>"+indexMarkers+"</aantal>";
rssFeed += "<userid>"+_loginid+"</userid>";
rssFeed += "</route>";
opslaanR.send();
else
Alert.show("U moet markers toevoegen om op te slaan!");
else
Alert.show("U moet een routebeschrijving toevoegen om op te
slaan!");
The httpservice looks like this:
<mx:HTTPService
id="opslaanR"
url="url"
useProxy="false"
method="POST"
resultFormat="e4x"
result="opslaanSucces(event)"
showBusyCursor="true"
>
<mx:request>
{rssFeed}
</mx:request>
</mx:HTTPService>
The "aantal" tag is the number of markers a route holds.
Basically I want to loop the $_POST variables in php using "aantal"
so I can add them to my database. The PHP works flawlessly but it
never gets the httpservice values.
Please help.

well you understood me, I want an alternative to the script what I put in AS2,
but I think. of the script as you sent me centenary assume that I have in the library button menu0 menu1 .....
But I have only one menu button.
because I tried it and it did not work.
var ClassRef: Class = Class (getDefinitionByName ("menu" + i));
I will be happy if later you look again

Similar Messages

  • [svn] 949: Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name , it causes a ClassCastException in the server

    Revision: 949
    Author: [email protected]
    Date: 2008-03-27 07:12:59 -0700 (Thu, 27 Mar 2008)
    Log Message:
    Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name, it causes a ClassCastException in the server
    QA: Yes - try again with legacy-collection true and false.
    Doc: No
    Checkintests: Pass
    Details: Another try in fixing this bug. When legacy-collection is false, Actionscript Array on the client becomes Java Array on the server and my fix yesterday assumed this case. However, when legacy-collection is true, Actionscript Array becomes Java ArrayList on the server. So added code to handle this case.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-96
    Modified Paths:
    blazeds/branches/3.0.x/modules/proxy/src/java/flex/messaging/services/http/proxy/RequestF ilter.java

    Hi all!
    Just to post the solution to this if anyone ever runs accross this thread...
    For some reason i had it bad the first time, don't have time right now to see why but here is what worked for me:
    HashMap primaryFile = new HashMap();
    primaryFile.put("fileContent", bFile);
    primaryFile.put("fileName", uploadedFile.getFilename());
    operationBinding.getParamsMap().put("primaryFile", primaryFile);
    HashMap customDocMetadata = new HashMap();
    HashMap [] properties = new HashMap[1];
    HashMap customMetadataPropertyRoom = new HashMap();
    customMetadataPropertyRoom.put("name", "xRoom");
    customMetadataPropertyRoom.put("value", "SOME ROOM");
    properties[0] = customMetadataPropertyRoom;
    customDocMetadata.put("property", properties);
    operationBinding.getParamsMap().put("CustomDocMetaData", customDocMetadata);
    Basically an unbounded wsdl type is an array of objects (HashMaps), makes sense, i thought i had it like this before, must have messed up somewhere...
    Good luck all!

  • [svn] 931: Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name , it causes a ClassCastException in the server

    Revision: 931
    Author: [email protected]
    Date: 2008-03-26 11:31:01 -0700 (Wed, 26 Mar 2008)
    Log Message:
    Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name, it causes a ClassCastException in the server
    QA: Yes - we need automated tests for this basic case.
    Doc: No
    Checkintests: Pass
    Details: RequestFilter was not handling multiple headers with the same name properly.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-96
    Modified Paths:
    blazeds/branches/3.0.x/modules/proxy/src/java/flex/messaging/services/http/proxy/RequestF ilter.java

    Hi all!
    Just to post the solution to this if anyone ever runs accross this thread...
    For some reason i had it bad the first time, don't have time right now to see why but here is what worked for me:
    HashMap primaryFile = new HashMap();
    primaryFile.put("fileContent", bFile);
    primaryFile.put("fileName", uploadedFile.getFilename());
    operationBinding.getParamsMap().put("primaryFile", primaryFile);
    HashMap customDocMetadata = new HashMap();
    HashMap [] properties = new HashMap[1];
    HashMap customMetadataPropertyRoom = new HashMap();
    customMetadataPropertyRoom.put("name", "xRoom");
    customMetadataPropertyRoom.put("value", "SOME ROOM");
    properties[0] = customMetadataPropertyRoom;
    customDocMetadata.put("property", properties);
    operationBinding.getParamsMap().put("CustomDocMetaData", customDocMetadata);
    Basically an unbounded wsdl type is an array of objects (HashMaps), makes sense, i thought i had it like this before, must have messed up somewhere...
    Good luck all!

  • Timeout in resultHandler for HTTPService request

    Hello All,
    I have a flex application where I am calling to get data in XML format.  The data file most likely will contain 10's of thousands of records (in most cases).  What I am experiencing is a timeout in my rHandle function (see code snippets below):
    Error #1502 A Script has executed for longer than the default timeout period of 15 seconds
    My question/problem has 2 parts.
    1) how do you disable the timeout?
    2) the reading/parsing of the XML data seems to take waaaay too long.  Is there a better way?
    I put an Alert message at the top of the result handler function and it didnt trigger before the timeout message triggered.  I am reading what could be 10's of thousands of records.  Is there a better (and FASTER) way to do this than to read in XML format?  Currently, no matter what I set the httpservice requests 'timeout' value to doesnt seem to have any effect.  I get a timeout after 15 seconds every time.  I have tried setting the timeout value to -1 (as documentation suggested) and/or to some very large value (say, 1200...20 minutes).  Any and all help is appreciated.   Here is the code and an example of the XML file
    private var contactService:HTTPService = new HTTPService();
    private var xData:XML;
    private var T_Data:ArrayCollection = new ArrayCollection();
    private function get_data():void
       contactService.url="data/big_data.xml";
       contactService.format = "e4x";
       contactService.addEventListener(ResultEvent.RESULT, rHandle);
       contactService.requestTimeout = -1;
       contactService.send();
    private function rHandle(event:ResultEvent):void
       var i:int;
       xData = event.result as XML;
       for  (i=0; i < xData.el.length(); i++)
          var t:Object = new Object();
          t.cid = xData.el[i].cid; 
          t.date = xData.el[i].date; 
          t.y_axis = xData.el[i].y_axis;
          T_Data.addItem(t);
    <mx:PlotChart.....DataProvider="{T_Data}"
       <mx:horizontalAxis>
          <mx:DateTimeAxis />
       </mx:horizontalAxis>
       <mx:verticalAxis>
          <mx:LinearAxis />
       </mx:verticalAxis>
       <mx:series>
          <mx:PlotSeries id=... yField="y_axis" xField="date" />
       </mx:series>
    </mx:PlotChart.....
    contents of big_data.xml
    <xml.....>
    <data>
    <el><cid>1</cid><date>1243814400982</date><y_axis>10</y_axis></el>
    <el><cid>2</cid><date>1243814401982</date><y_axis>12</y_axis></el>
    <el><cid>3</cid><date>1243814451982</date><y_axis>44</y_axis></el>
    <el><cid>4</cid><date>1243815451730</date><y_axis>21</y_axis></el>
    .........(10s of thousands of records like this)....
    </data>

    Through trial and error, and some investigation, I found that the solution to my problem was to use remoteobject rather than httpservice.
    Flex doesnt seem to handle httpservice calls with XX meg feeds very well.

  • Status of the httpservice request?

    Im using httpservice to get XML from a live URL of a web service I run.... works great and Im just trying to make it a little more elegant and presentable... is there a way for me to have an animated busy indicator on the stage and have it sit on top (using depth control) of my list that populates with the XMl data... then based on the status of the httpservice request, toggle the depth so that when the xml has finished loading, the busy indicator drops beneath the list object (using a lower number for the depth).
    or maybe its better to have the list alpha change and just leave the busy indicator below the list -- either way -- Im trying to figure out how to use some type of listener routine (presuming thats how I'd do it) to get the status and check for some type of completion.
    heres the code Im using in FB 4.6 ...  if its a mess, please be kind... Im just beginning to dabble with FB (and having a real blast so far).
    <?xml version="1.0" encoding="utf-8"?>
    <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
                        xmlns:s="library://ns.adobe.com/flex/spark"
                        creationComplete="init(event)" splashScreenImage="@Embed('logo.png')"
                        title="Events Listing Demo">
    <fx:Script>
                        <![CDATA[
                                  import mx.events.FlexEvent;
                            import spark.events.IndexChangeEvent;
                                  protected function init(event:FlexEvent):void
                                            lfXML.send();
                                  protected function list1_changeHandler(event:IndexChangeEvent):void
                                            navigator.pushView(Detail, event.target.selectedItem);
                                  protected function btnreload_clickHandler(event:MouseEvent):void
                                            navigator.pushView(HomeView);
                        ]]>
    </fx:Script>
    <fx:Declarations>
      <s:HTTPService id="lfXML" url="URL TO MY XML SERVICE HERE"/>
    </fx:Declarations>
              <s:List id="list1" y="191" left="10" width="460" height="407" change="list1_changeHandler(event)"
                                  contentBackgroundAlpha="90"
                                  dataProvider="{lfXML.lastResult.Events.EventListing}" depth="6"
                                  labelField="EventTitle">
    </s:List>
              <s:BusyIndicator id="indicator1" y="280" width="180" height="165" depth="5" horizontalCenter="0" />
              <s:Button id="btnreload" x="109" label="Reload Events Data" click="btnreload_clickHandler(event)"
                                    verticalCenter="301"/>
    <s:Image x="10" y="2" width="460" height="173" source="@Embed('views/logo.jpg')"/>
    </s:View>

    After making a call, HTTPService fires a FaultEvent (if there was a failure) or ResultEvent (if there was a success).
    Therefore, all you need to do is to display the busy indicator after any .send() and hide it again in response to any FaultEvent or ResultEvent.
    EG: You could do this using states like this.
    [code]
    <fx:Script>
    <![CDATA[
    import mx.events.FlexEvent;
    import mx.rpc.events.FaultEvent;
    import mx.rpc.events.ResultEvent;
    protected function init(event:FlexEvent):void
    lfXML.send();
    currentState = "loading";
    protected function lfXML_faultHandler(event:FaultEvent):void
    // TODO Auto-generated method stub
    currentState = "ready";
    protected function lfXML_resultHandler(event:ResultEvent):void
    // TODO Auto-generated method stub
    currentState = "ready";
    ]]>
    </fx:Script>
    <s:states>
    <s:State name="ready" />
    <s:State name="loading" />
    </s:states>
    <fx:Declarations>
    <!-- Place non-visual elements (e.g., services, value objects) here -->
    <s:HTTPService id="lfXML"
    fault="lfXML_faultHandler(event)"
    result="lfXML_resultHandler(event)"
    />
    </fx:Declarations>
    <s:List id="list1" y="191" left="10" width="460" height="407" change="list1_changeHandler(event)"
    contentBackgroundAlpha="90"
    dataProvider="{lfXML.lastResult.Events.EventListing}" depth="6"
    labelField="EventTitle">
    </s:List>
    <s:BusyIndicator id="indicator1" y="280" width="180" height="165" depth="5" horizontalCenter="0"
    includeIn="loading"
    />
    <s:Button id="btnreload" x="109" label="Reload Events Data" click="btnreload_clickHandler(event)"
    verticalCenter="301"/>
    <s:Image x="10" y="2" width="460" height="173" source="@Embed('views/logo.jpg')"/>
    [/code]

  • HTTPService request for each View inside a ViewStack

    Can someone point me in the right direction to have a
    httpservice request for each view inside my viewstack?
    <mx:ViewStack id="views">
    <mx:Canvas id="view0">
    </mx:Canvas>
    <mx:Canvas id="view1">
    </mx:Canvas>
    </mx:ViewStack>
    Can someone whip together a quick example or just point me in
    the right direction?
    Thanks

    Ahh, don't do that.
    Use a central HTTPService instance, and use AsyncToken to
    keep track of which result goes where. Some code snippets below.
    Tracy
    Sample code using HTTPService, e4x, handler function to
    populate a list item.
    Also shows usage of AsyncToken.
    The DataGrid tag:
    <mx:DataGrid id="dg" dataProvider="{_xlcMyListData}"
    .../>
    The HTTPService tag:
    <mx:HTTPService id="service" resultFormat="e4x"
    result="onResult(event)" fault="..../>
    Script block declaration:
    import mx.rpc.Events.ResultEvent;
    [Bindable]private var _xlcMyListData:XMLListCollection;
    Invoke send:
    var oRequest:Object = new Object();
    oRequest.Arg1 = "value1";
    var callToken:AsyncToken = service.send(oRequest);
    token.callId = "myQuery1";
    Result Handler function:
    private function onResult(oEvent:ResultEvent):void {
    var xmlResult:XML = XML(event.result); //converts result
    Object to XML. can also use "as" operator
    var xlMyListData:XMLList = xmlResult.myListData; //depends
    on xml format, is row data
    _xlcMyListData = new XMLListCollection(xlMyListData); //wrap
    the XMLList in a collection
    trace(_xlcMyListData.toXMLString()); //so you can see
    exactly how to specify dataField or build labelFunction
    var callToken:AsyncToken = oEvent.token;
    var sCallId = callToken.callId; //"myQuery1"
    switch(sCallId) {
    case "myQuery1":
    doQuery2();
    break;
    }//onResult

  • How I can create dynamically-formed requests or use native SQL in EJB?

    Hi all.
    I'm working around modify an example from NetWeaver Developer Studio (CarRental). I want to get ordered data from table and allow users to specify the ordering field, not in the code. EJB QL doesn't support dynamically-formed queries like "select object(b) from QuickBooking b where b.status like ?1 order by b.<b>?2</b>" so i can't passing field name as parameter into query. Creating a sorting method for every field is not good solution because I need a dynamically-formed requests.
    I think using native SQL will help but I don't know how I can use SQL in EJB.
    Thanks,
    Lev

    import javax.persistence.EntityManager;within class, place
    protected EntityManager  entityManager;of course make it public, private, whatever you need.
    Then, in your method
    entityManager.createNativeQuery(....);R. Grimes

  • Multiple Httpservice requests

    Hi,
    I have a requirement where i have to load two components on
    one click.
    And each component has httpservice request.
    function onclick is the following
    public function onclick(event:MouseEvent):void{
    this.loadComponentOne();
    this.loadComponentTwo();
    when i get the response correctly , the invoke and result
    events from httpservice are in this order
    Httpservice from component one in invoked
    result from component one is [object Object]
    HttpService from component two is invoked
    result from component two is [object Object]
    but sometimes there is a conflict between the responses from
    the httpservices of these components
    in this case,Events from httpservice output the result in
    this order
    Httpservice from component one in invoked
    HttpService from component two is invoked
    result from component one is [object Object]
    result from component two is [] //empty for some reaon
    i get the result from my servlet correctly but
    ResultEvent.result is empty
    and the component two is not loaded because the result is
    empty..
    so how should the multiple httprequests be handled to get the
    responses correctly?
    Thanks
    chandana

    I am using a separate class to create a httpservice.
    following is the code where i send the Httpservice with all
    the event handlers.
    and from the component i call the methods from this class to
    get the response as follows
    public function selectedEntitiesList(id:String):void{
    backendRequest = new MittoBackendRequest(list_url);
    backendRequest.setRequest({action:action,id:id});
    backendRequest.addEventListener(ResultEvent.RESULT,getList);
    backendRequest.send();
    Thanks
    chandana

  • Dynamic file request to appserver and static file request to webserver

    Can we redirect dynamic file request to appserver and static file request to webserver in any application and
    what are the best way to do it ?
    Waiting for the best suggestions ?

    when you have a large number of images/css/javascript/static(html/pdf/doc) files. It takes some of the processing load from your app server and also reduces the network traffic (otherwise traffic must flow between webserver and weblogic as well). it is also reasonably trivial to configure cache/modification/etags headers from a webserver and they are probably more featured than a weblogic server (e.g. to turn on gzip for static files dynamic is just a setting in the webserver but probably needs a custom filter developed in weblogic).
    Again this applies if you already have a webserver (normally because your firewall policy dictates this approach). If you are considering whether to have a webserver at all then there are different considerations.
    regards
    deepak

  • First HTTPService request takes forever

    Ok.  I have an interesting event taking place with my application.
    The first HTTPService request takes about 10-20 seconds and then, any additional requests are made between 1-5 seconds.
    A user types in a country code that and clicks a submit button.  The request is sent to a PHP page with the variable, the PHP creates an XML response.  Flex updates a datagrid accordingly which shows rates/minute for phone numbers with that country code.
    Any suggestions as to why this might be?
    Thanks in advance.
    Other Thoughts:
    First Request = 7 results (about 15 seconds)
    Second Request = 168 results (1 second)
    Third Request = 3028 results (5 seconds)
    Fourth Request = same request as First request (less than 1 second).

    im not sure about that one. i havent seen that issue before. as for the 'if i delete itunes, will it delete my music' question, the answer is no. if you uninstall itunes, it will just leave your music on your computer.

  • Multipe Flex Apps Multiple HttpService request fails

    I have multiple flex apps on the same page.  Both make calls to different httpservices on creation complete.  90% of the time one will fails with the useless generic 2032 error.
    The one request that fails never makes it to the webserver accroding to the logs.  In firebug is says the connection was closed - maybe the browser is closing it?  I have verified that the service url is not cached.  Is this is a known limitation with how flex is making httpservice request behind the scenes that it cant handle multiple apps on the same page??
    Anybody have this issue and know of a workaround?

    I have multiple flex apps on the same page.  Both make calls to different httpservices on creation complete.  90% of the time one will fails with the useless generic 2032 error.
    The one request that fails never makes it to the webserver accroding to the logs.  In firebug is says the connection was closed - maybe the browser is closing it?  I have verified that the service url is not cached.  Is this is a known limitation with how flex is making httpservice request behind the scenes that it cant handle multiple apps on the same page??
    Anybody have this issue and know of a workaround?

  • Tree Doesnt populate the whole data with HTTPService request

    Hi,
    I am working with the tree control which populates the tree
    with the HTTPService request.
    Step1. Make a HTTPService Request and fetch the top level
    entries.
    Step2. When ever the user opens an treeItem by clicking on
    the Triangular icon besides the tree item
    Make a HTTPService, fetch the data, on the callback method
    append the Datasource with the new data for the item to open.
    problem is the tree branch gets populated with partial data
    instead of the full data where as the DataSource has the full data.
    Step3. when ever the user clicks on the item
    Make a HTTPService, fetch the data, on the callback method
    append the Datasource with the new data for the item to open.
    Now the tree item gets populated with the correct data.
    tried every thing to refresh the tree....

    private function refreshTree():void{
    tree.expandItem(rootNode, false);
    tree.expandItem(rootNode, true);
    this helped

  • Dynamic HTTPService URL

    How about when i wanted my HTTPService url to become dynamic
    that it gets from an external text file or xml file. Here is an
    exampl...
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="
    http://www.adobe.com/2006/mxml"
    xmlns:remoting="com.oreilly.
    programmingflex.rpc.*" layout="absolute"
    initialize="initializeHandler(event)">
    <mx:Script>
    <![CDATA[
    private function initializeHandler(event:Event):void {
    textService.send( );
    private function resultHandler(event:Event):void {
    textArea.text = String(textService.lastResult);
    ]]>
    </mx:Script>
    <!--<mx:HTTPService id="feedRequest" url="ip.txt"
    result="resultHandler(event)" useProxy="false"/>-->
    <mx:HTTPService id="textService" url="
    http://yourdomainname.com/ip.xml"
    result="resultHandler(event)" />
    <mx:TextArea id="textArea" width="500"/>
    <mx:VideoDisplay id="vid"
    source="{textService.lastResult.subscribers.thevideo}" width="450"
    height="338" x="20" y="75" />
    </mx:Application>
    As you can see my HTTPService URL points to a file named
    ip.txt, the file includes my database URL where i will get my files
    to be played in my VideoDisplay. Is there anybody who can help me
    with this stuff. any reply would be very much appreciated.
    thanks!!!

    Are you asking if you can make the URL property of the
    HTTPService that points to the textService dynamic?
    You can bind the property to some local variable that is
    dynamically built:
    <mx:HTTPService id="textService" url="{someXMLFilePath}"
    result="resultHandler(event)" />
    The someXMLFilePath variable can be built in the
    initializeHandler ( or where ever you want).

  • Concurrent HTTPService requests - is it possible?

    I am a bit confused. I have several HTTPService objects that invoke different web services.
    I cannot seem to fire more than one at a time. If I fire off an HTTPService, then fire off another one, it seems that the first request is destroyed.
    I have the need to use a WebService I have written to handle the update of some data. I need to call this service six times (for each of the six calendar controls I have).
    I have argued with my architect that I should have ONE service to handle all six loads of data, at once. But currently it is written to handle only ONE month, hence my need to fire off this web service 6 times.
    Is this even possible? I use HTTPService objects...would I need to change the data access object to something like WebService object?
    How can I call six webservices, at once, without running into concurrency problems? Any ideas, I am completely lost on this one...help!
    By the way, my web services are written in .NET. I do not use ColdFusion or BlazeDS or anything else to layer my server. I speak directly to my web services via HTTPService objects. FYI.

    ^ Thank you so much. That was some great information and I will try to use the concurrency property on my HTTPService objects.
    I have been able to find very little info on this subject and I see it as being rather important. I noticed in other FLEX apps I have demoed and looked at, that there are multiple service calls happening, concurrently, so this leads me to believe it can happen. I just dont know how to make it happen for my application. Thanks for the tip.
    Also, I believe we are using WebService, not REST service. I noticed there are WebService objects in FLEX, where you can define multiple services in one object. I may need to switch to those type of objects instead of HTTPService. I am unsure.
    I would much rather make my application web service calls more transactional. I would rather it pass the 6-month data in one call, rather than 6 one month calls. It just seems that 1 call would be more efficient than 6. 6 calls would also require a lot more logic and more work. I am curious to see if I can make it work though, I'll run a test and find out. Thank you.

  • What is the proper way to set character encoding in an HTTPService request?

    I'm trying to get an HTTPService object's request to have
    proper character encoding. If I do nothing, I get "null" inside a
    Java servlet when I call getCharacterEncoding() on the request
    object. If I do this to my Flex HTTPService:
    httpService.contentType = "application/x-www-form-urlencoded;
    charset=UTF-8";
    then I get a valid character encoding (UTF-8) in the Java
    servlet as I should. But the problem is that my HTTPService's POST
    parameters are no longer coming along with the request. If I drop
    the charset value and set this instead in Flex:
    httpService.contentType =
    "application/x-www-form-urlencoded";
    then I get my POST params in my servlet just fine, but of
    course, no charset info.
    (For completeness, I am also setting: httpService.method =
    "POST"; and httpService.resultFormat = "e4x"; as well as the URL.)
    How do I send charset info without interfering with the
    transmission of the POST params? This is a serious flaw for anyone
    doing UTF-8 content, because most servers are going to assume
    ISO-8859-1 if you don't send anything specific. It's interesting
    that Flex is actually encoding in UTF-8. I know, because I am
    currently working around the problem by intercepting the HTTP
    request in my servlet and forcing the character encoding to UTF-8
    before binding the params. That's a lousy workaround, though.
    Hint to Flex 3 developers: It would be much more preferable
    to have a setCharacterEncoding method (or characterEncoding prop)
    on the Flex HTTPService.

    Hello,
    I realize this is an old thread, but the problem still seems
    to exist in Flex 3 and I run into it
    Unfortunately I don't understand the workaround.
    Could someone point out in a bit more detail how this should
    be done?
    Many thanks indeed,
    Peter
    _servlet = new HTTPService();
    _servlet.url= ...;
    _servlet.resultFormat=_resultFormat;
    _servlet.addEventListener(ResultEvent.RESULT,onServiceActionResult);
    _servlet.addEventListener(FaultEvent.FAULT,onServiceActionFault);
    _servlet.requestTimeout=_timeout;
    _servlet.contentType=_requestMimeType;
    _servlet.method=_method;
    XML.prettyPrinting=false;
    if(sdk13922Workaround) {
    _servlet.request=params;
    this._token=_servlet.send(null);
    } else {
    _servlet.request=request;
    this._token=_servlet.send(_params);
    quote:
    Text

Maybe you are looking for