Hi everyone, I have a snippet code that will create a qr code. But now I need to save it as image file. Can anyone kindly point the way how to do it?
The following is what I'm using so far.
The following is what I'm using so far.
B4X:
Sub qrCreator(vfname As String)
Dim qr As QRGenerator
qr.Initialize(ImageView1.Width)
ImageView1.SetBitmap(qr.Create(vfname))
Log("created!")
' I can not make the code below run properly
'Dim imgPreview As ImageView
'imgPreview.Initialize("")
'Dim b As Bitmap
'b.Initialize(File.DirRootExternal , vfname & ".jpg")
'b = imgPreview.Bitmap
'Dim out As OutputStream
'out = File.OpenOutput(File.DirRootExternal & "/" & AppName, vfname & ".jpg", False)
'b.WriteToStream(out, 100, "JPEG")
'out.Close
End sub