Anybody know the trick to make a web canvas visible and display it’s paint events?
I have a web canvas in a container control that displays an image on the paint event. If the default ContainerControl1.Visible property is True, everything works fine.
If I set the default ContainerControl.Visible property to False on startup and use a button to set ContainerControl1.visible = true, it refuses to display the image.
The code of the canvas Paint event is:
g.DrawPicture(MyPicture, 0, 0)
I have tried every permutation of the following lines of code and it still won’t display (I’m using Xojo 2016 R2). If I check the visible property of the canvas, it indicates that it is visible, but it’s like the Paint event isn’t occurring or something.
ContainerControl1.visible = true
ContainerControl1.Canvas1.invalidate(false)
ContainerControl1Canvas1.Refresh