Ok...maybe I've been staring at it too long to see what's wrong...and I swear this code used to work!
I'm trying to put a visual timestamp on a JPG...I take the picture, save it as "1.jpg", open it back up, slap it into an imageview, move the imageview into a canvas then use the canvas.drawtext method to timestamp it. Except it never gets there and dies during the canvas.initialize invocation ("Application has stopped unexpectedly").
I'm trying to put a visual timestamp on a JPG...I take the picture, save it as "1.jpg", open it back up, slap it into an imageview, move the imageview into a canvas then use the canvas.drawtext method to timestamp it. Except it never gets there and dies during the canvas.initialize invocation ("Application has stopped unexpectedly").
B4X:
If iview.IsInitialized = False Then
iview.initialize("")
Activity.AddView(iview,10,10,1600,1200)
iview.Gravity=Gravity.FILL
End If
iview.visible = False
iview.Bitmap=LoadBitmap(File.DirRootExternal,"1.jpg")
cnvs.Initialize(iview) ' CRASHES HERE!
cnvs.DrawText(Label1.Text,30,20,Typeface.DEFAULT,15,Colors.White,"LEFT")