Sub updateNext
Dim Cursor1 As Cursor = Starter.SQL1.ExecQuery("SELECT image FROM table1 WHERE rowID = " & Starter.lstRowIDs.Get(Starter.posNext))
Dim binimageR() As Byte, OtptR As InputStream
Cursor1.Position = 0
binimageR = Cursor1.GetBlob("image")
OtptR.InitializeFromBytesArray(binimageR, 0, binimageR.Length)
BmpR.Initialize2(OtptR)
OtptR.Close
Dim outR As OutputStream = File.OpenOutput(File.DirInternal, "Picturer.jpg" , False)
BmpR.WriteToStream(outR, 100, "JPEG") ' write the bitmap to the stream
outR.Close
Cursor1.Close
btnN.Bitmap = ri.CreateBitmap(LoadBitmap(File.DirInternal,"Picturer.jpg"))
End Sub