Reading objects sent via URLRequest

I'm trying to send and object to a servlet (a ByteArray which
I can then encode into and image file in java) and following the
documentation, I think this is the proper method to send it
(component is a UIComponent such as a Panel)
var imageSnap:ImageSnapshot =
ImageSnapshot.captureImage(component);
var imageByteArray:ByteArray = imageSnap.data as ByteArray;
var request:URLRequest = new URLRequest(url);
request.data = imageByteArray;
request.method = URLRequestMethod.POST;
navigateToURL(request);
But I have no idea what to do with the request.data in the
servlet. How do I access is as a byte array in the servlet?

Wrap your object data into one or more packets, then add an ending tag in the trailer of the last packet ?

Similar Messages

  • Send complex data via web service : discards parts of complex object sent

    Hi,
       I have to send an object to the server via a web service. The object A (say) that is being sent has a lot of properties. Now A has an array collection of objects of type B which in turn has an array collection of type C and so on..
    The problem is some of the data is not a part of the xml data sent out.
    I have included the snapshots of the data given to the web service and data sent out as seen in the network monitor below.
    Object sent to the web service
    xml data sent out as seen
    in the request body in the Network monitor
    The object in red rectangle above is of type "Slide" which has an object "caption" of type Caption and other simple properties like slideId (int), slideNumber(int) and storyBoardId(int).
    The object in the red rectangle is the xml data of "Slide" corresponding to the object in the red rectangle in the image to the left.
    Notice that the entire object "caption" has been dropped while the simple properties have been represented.
    I am stuck and cant find a solution to this issue or a work around
    any pointers would be really helpful.
    thanks in advance

    Posting more images .. have simplified the object a lot but still have the same issue.
    1. The request object description as given in the asmx [seen in the browser]
    2. The request object's description as given in the wsdl [seen in browser]
    3. The object that is being sent to the web service -- as seen in the debugger of Flash builder
    4. The object data in xml being sent out of Flex client -- as seen in network monitor of Flash Builder
    NOTE : The object data as seen in the network monitor doesnt have the caption" part at all! whereas the debugger shows the caption.
    5. The object recieved at the web method  of the web service -- as seen in the debugger of visual studio running the service
    If anyone has any work around for this pl let me know.

  • Visa read object difference parity setting for PC and TPC2012 device

    Hello,
     we found some difference between application running in PC and runing in TPC2012 device.
    We tested modbus communication via RS485 (9600b/s, 8bits, parity even) between PLC(master) and TPC2012 (slave). We used Visa read object and set parity to Even via property node. From the PLC we sent request to device and in our application we only read the data from PLC and displayed it (8bytes) on sreen.
    If we tested the application on PC everything worked fine. But if we compiled application and ran it in TPC2012 device  the data was different (for example if I sent request from PLC to slave 05 03 00 01 00 01 crc crc on the TCP I saw 00 03 00 01 00 01 crc crc. The  crc on TPC wasn't equal to crc on PLC.
    We found that problem was in VISA read setiing for read data in TPC device. If we set parity to SPACE (instead of EVEN)  then we read data correctly.
    Modbus - Parity set for VISA read object:
    Master PLC (even) - PC (even) -> visa read - data are equal
    Master PLC (even) - TPC (even) -> visa read - data aren't equal
    Master PLC (even) - TPC (space)-> visa read - data are equal 
    PC: Win XP SP2, LabView 8.5 with LabView TP module 8.5.
    TPC2012: WinCE 5.0, NI visa 4.2, NI TPC Service 1.0.
    Best regards,
    Pavel Rucka.

    I just found out that the VI for the currentmeasurement with the keithley 6517a has the same error but still works fine. Now I also tried to adjust the serial data bit and parity settings via the VISA configure serial port function but still no improvements.

  • JAN 4, 2012  As of the  Upgrade to   Lion,. and the  Email portion, ..   DOES NOT  allow a Video Clip to be sent via the Email  as the I-Photo is not supported by Video Clips  ( Previous Leopard  No problem  clip and drag  via Quick Time Pro to the email

    JAN 4, 2012 
    As of the  Upgrade to   Lion,.   2007  I-Mac  -   the  Email portion, ..   DOES NOT    allow a Video Clips to be sent via the Email 
    as the I-Photo is not supported by Video Clips  ( Previous Leopard ) 
    No problem  clip and drag  via Quick Time Pro to the email  and select the  Attchment  size to send. .  Depending on the 
    Size of the Video Clip  ..      Now  Lion only  Export's   1 size, .   only  and as a result . . teh  File is  TOO  Large and
    Will NOT  send via  E-Mail    ??? 
    Between the   Issue of   the   Lion,  and  Email  issues ,   and  the   Upgrade  of   I-Touch  to  5.1  from  4.2.1 
    as my  Photo  Size is  Huge ..    70,000  +  photos in the  Computer. .   and was   40,000  in the   I - Touch  .. .  
    The  New I-Touch  too will not Load the  same  as Previously  used  on  either  my  16 GB   or  32 GB   Unit . . 
              No Help . ..   so far, ..  as a Apple user   since   1996 ..    I  have Never  experieanced such  frustration    ??? 
                   (  any one have some help  if similar  experiances    ?     thank you     )

    JAN 4, 2012 
    As of the  Upgrade to   Lion,.   2007  I-Mac  -   the  Email portion, ..   DOES NOT    allow a Video Clips to be sent via the Email 
    as the I-Photo is not supported by Video Clips  ( Previous Leopard ) 
    No problem  clip and drag  via Quick Time Pro to the email  and select the  Attchment  size to send. .  Depending on the 
    Size of the Video Clip  ..      Now  Lion only  Export's   1 size, .   only  and as a result . . teh  File is  TOO  Large and
    Will NOT  send via  E-Mail    ??? 
    Between the   Issue of   the   Lion,  and  Email  issues ,   and  the   Upgrade  of   I-Touch  to  5.1  from  4.2.1 
    as my  Photo  Size is  Huge ..    70,000  +  photos in the  Computer. .   and was   40,000  in the   I - Touch  .. .  
    The  New I-Touch  too will not Load the  same  as Previously  used  on  either  my  16 GB   or  32 GB   Unit . . 
              No Help . ..   so far, ..  as a Apple user   since   1996 ..    I  have Never  experieanced such  frustration    ??? 
                   (  any one have some help  if similar  experiances    ?     thank you     )

  • I am using an apple TV to show a slide show which is sent via WiFi from a mini computer.  The slide show repeats for a few hours and then stops and shows "no signal".  What's going on- and how do I get the show to cycle indefinitely?

    I am using an apple TV to show a slide show which is sent via WiFi from a mini computer.  The slide show repeats for a few hours and then stops and shows "no signal".  What's going on… and how do I get the show to cycle indefinitely?  (I have set the server to NEVER sleep)

    Welcome to the Apple Community.
    Have you also set the Apple TV not to sleep.

  • Server hangs up when tryin to read object Urgent Help Plz

    Hi,
    I've been working on a client-server model for a while, I've tested my applicaction a thousand of times locally (I mean, server and serveral clients running on the same machine) and it's ok, now I finally run server in a remote host and I find it rarely works fine, most of the times server hangs up when tryin to read objects I dont know why.
    this is the part of the server-code where the problem begins:
    public int EscucharSocket(){
            Socket cliente = null;
            System.out.println("Servidor en escucha...\n");
            while(true){
                try{
                    cliente = SocketS.accept();
                    //I get client's ip and port
                    String ip = cliente.getInetAddress().getHostAddress();
                    int puerto = cliente.getPort();
                    //After the conexion is made, server reads a signature to
                    //identify the client
                   //in function process I check if the signature is valid
                   //SignedData is a class where I wrap the signiture (obviously
                   //it implements Serializable interface
                   process((SignedData)le.LeerObject(cliente));
                   //Other things done here
                catch (Exception e) { }
    }le is a class I use to read,write data to the socket, this is the code of the LeerObject function
    public Object LeerObject(Socket c) throws Exception {
           //Here Is where the server hangs up
            ObjectInputStream b = new ObjectInputStream(c.getInputStream());
            return b.readObject();
    }As I wrote when running locally, there is no problem, but when I have a remote host, that happens
    Any help or idea?

    Hi again, thnx for your help
    I modified my LE class so I just create a couple of Input/Output Streams per client (on server n client program), this is now the complete code of the class:
    import java.net.*;
    import java.io.*;
    public class LE {
        DataOutputStream     dos;
        ObjectOutputStream  oos;
        DataInputStream        dis;
        ObjectInputStream     ois;
        //Streams are created just once in the constructor
        public LE (Socket s) throws Exception {
            dos = new DataOutputStream(s.getOutputStream());
             //I'm not sure if this flush has any sense
            dos.flush();
            oos = new ObjectOutputStream (s.getOutputStream());
            oos.flush();
            dis = new DataInputStream(s.getInputStream());
            ois = new ObjectInputStream (s.getInputStream());
        public void EscribirByte(byte datos[],int len) throws Exception {
            dos.write(datos,0,len);
            dos.flush();
        public void EscribirString(String dato) throws Exception {
            dos.writeUTF(dato);
            dos.flush();
        public void EscribirChar(char dato) throws Exception {
            dos.writeChar(dato);
            dos.flush();       
        public void EscribirInt(int dato) throws Exception {
            dos.writeInt(dato);
            dos.flush();
        public void EscribirLong(long dato) throws Exception {
            dos.writeLong(dato);
            dos.flush();
        public void EscribirObject(Object dato) throws Exception {
            oos.writeObject(dato);
            oos.flush();
        public String LeerString() throws Exception {       
            return dis.readUTF();
        public int LeerInt() throws Exception {       
            return dis.readInt();
        public char LeerChar() throws Exception {       
            return dis.readChar();
        public long LeerLong() throws Exception {       
            return dis.readLong();
        public Object LeerObject() throws Exception {       
            return ois.readObject();
    }part of code of server and client, where the conexion is made and the LE object is created
    Server:
    try{
           cliente = SocketS.accept();               
           //After accepting the conexion the LE object is created
            le = new LE(cliente);
            //I get client's ip and port
            String ip = cliente.getInetAddress().getHostAddress();
            int puerto = cliente.getPort();
            //Object wraping signature is read        
            process((SignedData)le.LeerObject());
            //other control operations doing here
            //A thread is created to receive requests from client
            //(reference to LE object is passed to the thread
           ConexionCliente c = new ConexionCliente (cliente,id_persona,id_grupo,tipo_usuario,backup,le);                               
            //thread is started
            c.start();
    catch (Exception e) {
        try {
            cliente.close();
        catch(Exception e2){}
    }Cliente code:
    try{
       //it connects to the server
       c=new Socket(host,puerto);
       //After accepting the conexion the LE object is created         
       le = new LE(c);
       //other things made here to genarate SignedData Object
      //It sends signed data object
      le.EscribirObject(Data);          
      //A thread is created and started to receive messages from server
      //reference to object LE is sent to the thread to avoid the need of
      //creating another
      new ConexionServidorClient(c,id_persona,ci,le).start();
      return 1;
    catch(Exception e) {
       return -1;
    }after the change, itworks a little better, but still most of the times server hangs up, I can't make server operational yet and I dont have any idea for solving this issue

  • IPhone 5 - "Not Delivered" Message for Pictures Sent via iMessage

    I have received the "not delivered" message when trying to send a picture message via iMessage. The pictures actually are received by the other parties, yet I still get the error message, as do other parties when trying to send photos to me. If the picture is sent via text they send without the error message. Does anyone have any information that could help me with this problem?
    I have the 32GB iPhone 5 on iOS 7.1.1.

    Any errors when attempting to view pics?
    Have you tried Settings > General > Reset > Reset Network Settings?

  • MfE uninstall - Sent via Mail for Exchange still e...

    Hi,
    On my new N97 I accidentally installed MfE trough the Wizard. Later I removed MfE succesfully, but now in the Contact list, under E-Mail there still is an entry "Sent via Mail for Exchange".
    How can I remove that entry?
    Best regards,
    Wouter

    Check in Messaging and see if Mail for Exchange is still listed as a folder.
    If so, go to Options, Settings, E-Mail and you migth be able to remove it from there.

  • Contacts not shown in messages sent via PC Suite

    Hi all,
    OS : Windows XP SP2
    Connectivity : USB CA 101
    Handset : Nokia N 82
    Handset details : V 30.0.019
    RM-313
    Issue : If i send any message from my phone, in sent folder the contact person's name will display whereas for the messages sent via pc suite's communication centre, in sent folders only numbers are displayed despite the contacts are stored in the phone, same contacts' name will displayed if a message is sent via phone??? Is it an issue? Known bug from PC Suite ???

    there may be differencies between phone models here (S60 devices or S40 devices, you have S40). Also if I recall right, it used to be so that some older versions of PC Suite did not save the PC sent sms's to phone.
    However, with my N95 the messages are saved. So make sure you have the latest Pc Suite and then try again. If it fails, then it might be that message saving is not supported with S40 phones (Anyone having a S40 phone could verify this)

  • Outbound exchange mail being sent via SMTP instead of activesync

    This is kind of an advanced configuration and question, I'm pretty sure this is a bug but not sure how to get it to the right audience. I have several email accounts configured on my iPhone, two of the accounts share the same email address but are on two different servers; one an Exchange and the other a POP/SMTP server. The reason for this is that my domain has two MX records, the POP/SMTP being set up with a lower priority and acts as my backup server in the event my Exchange server is unavailable. The POP/SMTP server is hosted by registrar, where I host my own Exchange server.
    What I noticed is that when I have my POP/SMTP account set to active, any outbound mail I send via my Exchange account is being sent via my POP/SMTP account and NOT the activesync connector for the Exchange account. This shouldn't be happening, how do I report this to Apple?
    -Keith

    Anyone out there have a fix for this or know if this issue even hits Apple's radar for a fix?

  • Getting info on objects loaded via xml

    Hello:
    i am a beginner/intermediate as3 coder, and i am stuck on
    something related to objects loaded via XML.
    i am able to load JPEG images onto a simulated "shelf", but i
    am trying to arrange them on the shelf (like a store shelf) so that
    each new item is placed directly next to the previous item as they
    load. i can get it to work on a very basic level by specifying the
    spacing between items manually betwen the code, but to makre this
    reuseable and efficient, the ideal is to have the "next" object
    loaded be placed on the shelf based on the width of the previous
    object. but when i try to access the width of the object that is
    loaded via the imageLoader, i can;t find it. if i trace the image
    loader wifth, it is 0; i have tried several ways to name the object
    as it loads and then get/save its dimensions somehow, but i am not
    having any luck. i use all the Lynda titles and i also use some of
    the better books, but i just can;t seem to solve this.
    any hellp would be appreciated.
    thank you.

    Thak you for this -- it did help somewhat, but i am still
    stuck.
    When i use the contentLoaderInfo listener, you are right, i
    can discern the width of the loader. but when i do this it only
    works for the last item loaded. here is my problem -- i am trying
    to load graphics dynamically, and have each graphic go to it's
    proper "place" on a simulated shelf -- so the foirst object might
    go to (0,0), then next object should go directly to the right of
    the first object, etc, etc. and i am loading all this dynamically
    from an xml file. if i just specify a distance, then i can get
    everything to load at uniform distances from each other. problem is
    each of the graphics has a unique width, height, etc, so i need to
    be able to "catch and capture" this info as each one is loaded.
    when i wait until the entire loader has loaded, the only
    peopoerties left for me to capture and use are the propoerties of
    the last itm loaded.
    any ideas on how to do this -- anyone?
    thanks very much, i just can't seem to figure this out.

  • Add "Sent via" Line To Outgoing E-Mail From TREO 700wx

    I have a couple of users who would like to have the "Sent via" line added to e-mail that they send from their TREOs.  This is similar to the line added to an outgoing e-mail message when being sent from a BlackBerry device.  Is this possible?  I've looked everywhere in the phone that I can think of, but have come up empty.  Any information would be greatly appreciated.
    Post relates to: Treo 700wx (Verizon)

    AS you've seen on the Blackberrys  that message "Sent by my Blackberry" is basically a footer or signature on the message. On the 700wx to set this up you need to go to Start>Messaging>Menu button>Tools>Options and it should open to the accounts tab at the botton with a signatures button on the right side. Click on the signatures button and There you select the account and whether you want to use it for replies and forwarding as well.

  • TS1702 I had deleted my Apps Icon from the phone as I was trying to update the new version iOS4.3. However, after deleteing the Icon, I am not able to install the Apps Messenger again because I am not able to use the IOS.4.3 diagnostic password sent via e

    I had deleted my Apps Icon from the phone as I was trying to update the new version iOS4.3.
    However, after deleteing the Icon, I am not able to install the Apps Messenger again because I am not able to use the IOS.4.3 diagnostic password sent via email.
    Installation was rejected because I need the iOS.4.3
    Thanks for your help
    Michael

    That situation went from inconvenient to complicated quickly.  Wait for any pending orders to drop off, wait for things to clear up, wait till your upgrade comes up and then upgrade when your contract is fulfilled.  I would have suggested a replacement phone, I know, with only a month left why couldn't you just upgrade early, but these situations where people try to upgrade early always end horribly and once a phone order starts, it almost cannot finish until something winds up shipped received and returned.  Sorry this happened the way it did.  Definitely not efficient.

  • Receive email and read email attachment via BPEL

    Hi All,
         Does anyone know how to or has a module on receiving email and read email attachment via BPEL.
         Im now reading and exploring UMS adapter as this activity can handle both reading email and email attachment.
         Your response/s will be very much appreciated. Thanks.

    943363 wrote:
    Hello,
    I have an Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bits on an AIX 5.3 mainframe without the enterprise web interface.
    I would like to do that process :
    a daily email is sent to the oracle instance with a CSV in attachment.
    I would like that attachment in a directory configured onto the instance.
    I have a PL/SQL procedure triggered by a job that will insert the content of the CSV in a table.
    Is that process possible with what I have ?
    Thanks in advance,
    Best Regards,
    Grégory B.Databases don't receive email. Just sftp the file and schedule a job to process it.

  • Messages sent via comcast on ipad are received garbled

    email messages sent via comcast from Ipad are received garbled

    send me one so I can see what you are talking about (tom at bluesky dot org).

Maybe you are looking for