I have a .Net webservice with a method that is successfully returning an image from a DB BLOB field. I succesfully tested reconstruction of the image in a .Net client.
Now using Basic4Android, I'm really struggling to successfully get anything into a Bitmap type. The webservice itself is being called and the expected result is being returned in the webrepsonse, however after trying all manner of conversions I keep receiving "Error loading bitmap" errors.
Any help greatly appreciated.
For information, my data stream is being returned as <base64Binary> from the webservice, this is my latest attempt to get the image:
Sub GetProductImageFullSize_EndElement(Uri As String, Name As String, Text As StringBuilder)
If Name = "GetProductImageFullSizeResult" Then
Dim b() As Byte
Dim bmp As Bitmap
Dim s As StringUtils
Dim i As InputStream
b =s.DecodeBase64(Text)
i.InitializeFromBytesArray(b,0,b.Length)
bmp.Initialize2(i)
i.Close
Activity.SetBackgroundImage(bmp)
End If
End Sub
Now using Basic4Android, I'm really struggling to successfully get anything into a Bitmap type. The webservice itself is being called and the expected result is being returned in the webrepsonse, however after trying all manner of conversions I keep receiving "Error loading bitmap" errors.
Any help greatly appreciated.
For information, my data stream is being returned as <base64Binary> from the webservice, this is my latest attempt to get the image:
Sub GetProductImageFullSize_EndElement(Uri As String, Name As String, Text As StringBuilder)
If Name = "GetProductImageFullSizeResult" Then
Dim b() As Byte
Dim bmp As Bitmap
Dim s As StringUtils
Dim i As InputStream
b =s.DecodeBase64(Text)
i.InitializeFromBytesArray(b,0,b.Length)
bmp.Initialize2(i)
i.Close
Activity.SetBackgroundImage(bmp)
End If
End Sub