Cause
This error occurs if your application code attempts to set the parent of a window control to an invalid value. This can be for one of the following reasons.
The parent object does not have an attached window
The parent object is a control that cannot have children
Action
Change your code accordingly.