Problem downloading multiple images in bytearray, Help !

Hi Everyone,
I m trying to download multiple images on my mobile as a part of my application.
On server side I have used System.arraycopy to merge arrays..
What I did on server side is as follows:
byte[] seperator={'%'};
totalImageArray=image1+seperator+image2
Please note everything is in bytearray.
Now on client side I m not able to extract two images seperately i.e. bytes before seperator and after seperator.
how do i do byte to byte comparison ?
Please guide me as to how I should do this..tips links snippet...??
Message was edited by:
siddhsdesai

Wht dont you send images seperate...
For example first write the size of first image as bytes and than write the first image. Then write the size of second image as bytes and than write the second image.
In the client side first read the first number and then read as many as that bytes then create first image. Then read the second number and then read as many as that bytes then create second image.
Server Side...
DataOutputStream toClient = new DataOutputStream (....);
toClient.writeInt(...); //send the sizeof first image as bytes
toClient.write(...);  //send the first image as byte array
toClient.writeInt(...); //send the sizeof second image as bytes
toClient.write(...);  //send the first second as byte array
toClient.flush();Client Side...
DataInputStream fromServer= new DataInputStream (....);
int firstsize=fromServer.readInt(); //read the sizeof first image as bytes
byte[] image1data=new byte[firstsize]; //image1 buffer
fromServer.readFully(image1data);  //read the first image as byte array
int secondsize=fromServer.readInt(); //read the sizeof second image as bytes
byte[] image2data=new byte[secondsize]; //image2 buffer
fromServer.readFully(image2data);  //read the second image as byte array

Similar Messages

  • I cannot import photos from any device to my iphoto program- the error message statesphotos cannot import because there was a problem downloading an image.  I cannot identify the image that is the problem.

    I cannot import photos to my iphoto from any of my devices.  The error message reads - iphoto cannot import your photos because there was a problem downloading an image.  I have deleted the last images- this did not help.  any suggestions?

    Details please
    What version of iPhoto? Of the OS? what devices are you haveing problems with? can you download teh photos to a desktop folder using image capture (in your applications folder) and import from there - or open with priview from there?
    LN

  • I am trying to upload my photos to iphoto. I keep receiving a error message that say "Iphoto cannot import your photos because there was a problem downloading an image" What do i Do?!

    I am trying to upload my photos to iphoto. I keep receiving a error message that say "Iphoto cannot import your photos because there was a problem downloading an image" What do i Do?!

    Remember: we cannot see your machine. There are 9 different versions of iPhoto and they run on 8 different versions of the Operating System. The tricks and tips for dealing with issues vary depending on the version of iPhoto and the version of the OS.  So to get help you need to give as much information as you can. Basic things like :
    - What version of iPhoto.
    - What version of the Operating System.
    - Details. As full a description of the problem as you can. For instance: 'iPhoto won't export' is best explained by describing how you are trying to export, and so on.
    - History: Is this going on long? Has anything been installed or deleted?
    - Are there error messages?
    - What steps have you tried already to solve the issue.
    - Anything unusual about your set up? Or how you use iPhoto?
    Anything else you can think of that might help someone understand the problem you have.
    As a Test:
    Hold down the option (or alt) key and launch iPhoto. From the resulting menu select 'Create Library'
    Import a few pics into this new, blank library. Is the Problem repeated there?

  • Downloading Multiple Images

    Hi all,
                 I am using NWDS 7.0. I have an requirement to download multiple image files.
    Images can be viewed by clicking the links provided in the tablecolumn. Images(JPG) are in mime folder. if i use the Fiel Download UI Element, it is openning multiple windows for downloading multiple images.
    But i need in such a way that if i click the check boxes in the table the corresponding images has to be downloaded in my local system in the action of button functionality under the table. How to do that.
    Please bring me an solution it would be helpful for me.
    Thanks in advance
    Regards,
    Malar

    Hi Thenmalar
    Check these thread
    1.[Images through Java API|Re: Unable to manage Images through Java API;
    2.[Upload and Download |https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b0e10426-77ca-2910-7eb5-d7d8982cb83f]
    3.[Uploading Multiple Offline Forms in Web Dynpro Java|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/302bdc70-9ece-2b10-e9b6-c7309eab601b]
    This thread(3) will help u to understand of downloading multiple item.
    Now for runtime selection and display is easy ,Just on click on check box internally we have to pass the id
    (name of the image )through context like
    if(checkbox 1)
    wdContext.currentContextElement().setImage("abc.gif");
    if()...
    Best Regards
    Satish Kumar

  • IPhoto says it cannot import my photos because there was a problem downloading an image, how do I fix this?

    Hello! So I have a Sandisk class 10 memory card and whenever I try to import photos onto iPhoto from the memory card it says "IPhoto cannot import your photos because there was a problem downloading an image". I have a Macbook Air and IPhoto 9.5.1.. I've tried a lot of what other people say on other questions like this and it still won't work! I've tried using image capture, creating a new library, and creating a new user to see if it worked there. I have enough space for the photos, so I'm not sure what the problem is. Please help, Thanks! 

    I had that happen a couple of times because even though the camera displayed the  picture there was a problem with the way it was saved to the chip - and that caused problems with all pictures after it.
    My version of IPhoto (ILIFE09) does show where the error occurs on direct import from the camera -- on the camera deleting the first picture where the error occurred allowed import of the others.   Once it was the first picture, once in the middle.
    Problem happened when I took a second picture before the first one was 100% finished saving.

  • HT1386 When trying to down load photos I get this message: iPhoto cannot import your photos because there was a problem downloading an image. What should I do to restore syncing my phone?

    I can't sync my iPhone 4 photos with my deck top. It all just stoped working. When trying to sync photos I get the following message:
    iPhoto cannot import your photos because there was a problem downloading an image.
    What do I need to do to get the syncing process back to normal?

    Hi there obywon!
    I have an article for you that can help you find some other ways to import those pictures from your iPhone onto your computer. You should try a couple of different programs that would import the photos into your computer. This first article can tell you the different programs that you will want to try when attempting to import photos:
    iOS: Importing personal photos and videos from iOS devices to your computer
    http://support.apple.com/kb/ht4083
    If you are still having issues with importing those photos, you will want to see this article for next steps on resolving this issue:
    iOS: Unable to import photos to computer
    http://support.apple.com/kb/ts3195
    Thanks for using the Apple Support Communities!
    Cheers,
    Braden

  • When trying to upload pictures from my camera I get this message although I have uploaded from the same camera in the pastiPhoto cannot import your photos because there was a problem downloading an image.

    When trying to upload pictures from my camera I get this message although I have uploaded from the same camera in the past, "iPhoto cannot import your photos because there was a problem downloading an image."

    Can you access the images with Image Capture (in your Applications Folder) ?

  • IPhoto cannot import your photos because there was a problem downloading an image.

    Running Mac OS X Lion 10.7.5 on MacBook Air and Iphoto '09 version 8.1.2 on iphone 5.
    Keep getting the "iPhoto cannot import your photos because there was a problem downloading an image" error message. Is this related to HDR photos or videos? What can I do to solve this?

    Running Mac OS X Lion 10.7.5 on MacBook Air and Iphoto '09 version 8.1.2 on iphone 5.
    Keep getting the "iPhoto cannot import your photos because there was a problem downloading an image" error message. Is this related to HDR photos or videos? What can I do to solve this?

  • I am importing videos from my canon sl1 to my macbook when i use iphoto is says "iPhoto cannot import your photos because there was a problem downloading an image." and when i use image capture it says "An error occured while importing. The item 'MVI_1040

    I am importing videos from my canon sl1 to my macbook air when i use iphoto is says "iPhoto cannot import your photos because there was a problem downloading an image." and when i use image capture it says "An error occured while importing. The item ‘MVI_1040'' Thanks in advance

    Can you access the images on the phone with Image Capture (in the Applications Folder) ?

  • I cannot move photos from iphone to MacBook.  I get an error message that says: Error downloading image. iPhoto cannot import your images because there was a problem downloading an image. How can I fix/remedy this?

    I am receiving an error message every time I plug my iPhone 4S into my MacBook: Error downloading image. iPhoto cannot import your images because there was problem downloading an image.  How can I fix/remedy this?

    try Image Capture - in your applications folder
    LN

  • HT2498 iPhoto cannot import your photos because there was a problem downloading an image. This keeps happening I need hlep

    iPhoto cannot import your photos because there was a problem downloading an image. This keeps popping up and its really titting me off. I use a Canon Rebel and I shot a video with it and I am trying to put it up on a website but I cant get it to import onto anytihng please FIX THIS!!!!

    Try using Image capture (in your applications folder) to move the video to the desktop and then import to iPhoto from there
    LN

  • I am unable to download all photos to computer.  At a certain photo I get the following message:  IPhoto cannot import your photos because there was a problem downloading an image.  How can I go around this  image

    I am unable to import all photos to IPhoto on computer.  At a certain photo the following message appears:  IPhoto cannot import your photos
    because there was a problem downloading an image.  How can I circumvent this particular image and import all other photos?

    I'm having the same issue.  i have imported everything but the offending photo from my iPhone.  problem is, with over 5000 pics, i have no idea how to find THAT ONE pic that won't import (bc I just get a greyed out pic image - with no data in iPhoto)
    any idea how to get "date taken" info of THAT ONE pic out of iPhoto (or any metadata) so I don't have to search 3 years of pictures?
    and I do apologize for hijacking.

  • HT204382 iPhoto cannot import your photos because there was a problem downloading an image.

    Why am i getting this message (iPhoto cannot import your photos because there was a problem downloading an image) when i try uploading a GoPro video?

    Why am i getting this message (iPhoto cannot import your photos because there was a problem downloading an image) when i try uploading a GoPro video?

  • Iphoto won't let me import my photos because it has a problem downloading an image

    I need to backup my phone because i'm getting a new one, but it won't let me back it up because i've no space left so since i have over 3000 photos in my photo library, i was going to import it to iphotos, but once i try to import it, i get a notification that it couldn't download an image. WHAT IMAGE? It won't tell me!

    There are 9 different versions of iPhoto and they run on 9 different versions of the Operating System. The tricks and tips for dealing with issues vary depending on the version of iPhoto and the version of the OS. So to get help you need to give as much information as you can. Include things like:
    - What version of iPhoto.
    - What version of the Operating System.
    - Details. As full a description of the problem as you can. For example, if you have a problem with exporting, then explain by describing how you are trying to export, and so on.
    - History: Is this going on long? Has anything been installed or deleted? - Are there error messages?
    - What steps have you tried already to solve the issue.
    - Anything unusual about your set up? Or how you use iPhoto?
    Anything else you can think of that might help someone understand the problem you have.

  • Keep getting import error when trying to import photos from my camera. "iphoto cannot import your photos because there was a problem downloading an image".  Can anybody help?

    Have a problem importing my photos to iphoto '11.  Keep getting an error message.  Tried deleting some photos from iphoto as well as my camera, but it didn't help.  Can anybody tell me why this is happening?

    what happens when you use Image Capture (in your applications folder) and see what happens
    LN

Maybe you are looking for

  • UTL_FILE works on Oracle 10 ?

    The following code works on Oracle 9.1.0.2. I would like to know if it will work on Oracle 10. vDiretorio_servidor_entrada varchar2(50):='c:\oracle_temp_dir\entrada'; vUTL_ARQUIVO:=UTL_FILE.fopen(vDiretorio_servidor_entrada,vArquivo,'r', 4000); utl_f

  • REF CURSOR RETURNED FROM STORED PROCEDURE OPENED WITH CURRENT_USER PRIVILEGES

    Hi. I was wondering if anyone knows when this bug will be fixed. The bug# is 899567 off of metalink. I am running into this problem as well, and we do not want to use OCI/SQLNet as the fix. We have an application with secure data concerns and only wa

  • Joining jsp and jstl

    first of all, i'm a newbie..sorry for my beginner question. <sql:setDataSource var="datasource" driver="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost/test"                    user="root" password="123"/> <sql:query var="ts" dataSource="${datasou

  • Help on testing algorithm time

    Hello everybody: I want to ask a question about testing algorithm time. In my program, I always got the encryption time is zero. And some times is 15ms or 16ms. I test the time like this (ignore the unnecessary part): long startTime = TimeCounter.sta

  • Alias 2 to iPhone 4

    Can my media be transferred from the Alias 2 to the iPhone 4. (Pics and ringtones)  The Alias2 is not a media manager supported phone.