Two Laptop Bag*
The moose likes Java Micro Edition and the fly likes KSOAP receiving image as byte array Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Mobile » Java Micro Edition
Bookmark "KSOAP receiving image as byte array" Watch "KSOAP receiving image as byte array" New topic
Author

KSOAP receiving image as byte array

achor elm
Greenhorn

Joined: Feb 23, 2005
Posts: 2
I am beginner in J2ME. I use ksoap, I want to receive an image as byte array. I cant understood like one the SoapPrimitive used. you could help me to write the SOURCE code
thank you
Excuse me for my English

SoapObject client = new SoapObject(url,"testimage");

HttpTransport ht = new HttpTransport(url,"testimage");

ClassMap classMap = new ClassMap (true);
ht.setClassMap (classMap);
imageString = new SoapPrimitive
(Soap.ENC, "base64", Base64.decode());

byte [] a = new byte[l024];
a = Base64.decode(imageString);
THANKS THANKS
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: KSOAP receiving image as byte array