[android-developers] Re: Getting all of a long string in DDMS?

2010-03-29 Thread Dilli
In your code you should read the complete data available in the responseStream because the stream may don't give complete data at one attempt. You need to call read method on responseStream till it ends. ( i.e: read bytes size -1) i.e read the data till you got end of stream. then convert it to

Re: [android-developers] Re: Getting all of a long string in DDMS?

2010-03-29 Thread dillirao malipeddi
Like int read_cnt = 0; byte[] byteresp = new byte[1024]; int len = responseStream.available(); while(read_cnt len) { int size = len - read_cnt; int nR = responseStream.read(byteresp, 0, (size1024?1024:(int)size));

[android-developers] Re: Getting all of a long string in DDMS?

2010-03-29 Thread Anna PS
Thanks. I've tried the following, but it just doesn't output anything at all - any ideas what might be wrong? I'll try to debug too: InputStream responseStream = method.getResponseBodyAsStream(); responseString =