Hi, I am not sure why the following code is not working. I'm calling a second form.
The code below is what I'm using when the form is called.
And in the "Write" button this is the code.
The code below is what I'm using when the form is called.
B4X:
Dim newForm As Form
newForm.Initialize("digiSignForm",530,380)
newForm.Resizable = False
newForm.RootPane.LoadLayout("MainPage")
newForm.ShowAndWait
pnDraw = xui.CreatePanel("")
'
'MainForm.AddView(pnDraw, ImageView1.Left, ImageView1.Top,ImageView1.Width, ImageView1.Height)
Log(ImageView1.Width & " " & ImageView1.Height)
mCanvas.Initialize(pnDraw)
mRect.Initialize(0, 0, ImageView1.Width, ImageView1.Height)
mCanvas.DrawBitmap(ImageView1.Snapshot, mRect)
And in the "Write" button this is the code.
B4X:
mCanvas.ClearRect(mCanvas.TargetRect)
mCanvas.DrawBitmap(ImageView1.Snapshot, mRect)
mCanvas.DrawText(TextField1.Text, 5, 24, xui.CreateDefaultFont(22), xui.Color_Black, "LEFT")