cbpporter Messages: 1401 Registered: September 2007
Ultimate Contributor
U++ control exist from the point they are constructed, so usualy you should have no problems. Exception is for controls that are linked to the underlying windows system, like TopWindow. In the constructor it is not guaranteed to have a HWND because your window is not open yet and for WinAPI it may not exist. In your button handler the window already exists and is open.
I would recommend adding a method that opens the window and sets the correct parameters if it must be done each time.