Called by the framework after a control's parent changes. This allows (for example) child controls to automatically hook events on their parent, giving better encapsulation.
[Visual Basic] Overridable Protected Sub ParentChanged( _ ByVal oldParent As Control, _ ByVal newParent As Control _ ) [C#] protected virtual void ParentChanged( Control oldParent, Control newParent ); [C++] protected: virtual void ParentChanged( Control* oldParent, Control* newParent ); [JScript] protected function ParentChanged( oldParent : Control, newParent : Control );