Very annoying bug in my software

I am trying to code a window that gives you a live preview of the a blank image with the dimensions specified. For the first run, the behaviour is as expected both times. But it does not behave how I want to the second time I debug. Here is the video to show what I mean:
https://www.dropbox.com/s/u7m8307f0a8403z/Untitled.mp4

Thanks

Please ask questions for more details, thankyou!!

Here is the link to a stripped down version of my project:
https://www.dropbox.com/s/kb3q79cuzd9i462/stripped.xojo_binary_project

I’m not sure what the unwanted behavior you’re referring to is, it seems to run the same no matter how many times I run it. But it does seem like when you type a number in, you aren’t adding the group box height to the window so it’s too short. Is this the problem you’re running into? Look in the LiveResizeCanvas’s “Resize” method for where I think that problem is.

The problem seems to be that something isn’t initialized quite right, so your Resize method keeps setting it to the minimum height. Without knowing the intent, it’s hard to go any further with it.