I have two images in a table. Now I have to store both of them in SQLite as blobs. but I am struggling to find a way to get it in scenario of two URLs. If it is one I can solve it. Can any one suggest me how to resolve this issue?
The code I am trying is:
private void callInsertion(String bid, String bbookId,String bname, String image1, String image2, String bdesc) throws IOException {
// TODO Auto-generated method stub
DefaultHttpClient mHttpClient = new DefaultHttpClient();
HttpGet mHttpGet1 = new HttpGet(image1);
HttpGet mHttpGet2 = new HttpGet(image2);
HttpResponse mHttpResponse = mHttpClient.execute(mHttpGet1,mHttpGet2);
if (mHttpResponse.getStatusLine().getStatusCode() == HttpStatus.SC_OK)
{
HttpEntity entity = mHttpResponse.getEntity();
if ( entity != null)
{
insertData(bid,bbookId,bname,EntityUtils.toByteArray(entity),EntityUtils.toByteArray(entity),bdesc);
}
}
}
But I am getting errors at client execution.
Try to get like this!!