UIViewController.WillMoveToParentViewController(UIViewController) UIViewController.WillMoveToParentViewController(UIViewController) Method


Called prior to adding or removing this from a container UIViewController.

public virtual void WillMoveToParentViewController (UIKit.UIViewController parent);
abstract member WillMoveToParentViewController : UIKit.UIViewController -> unit
override this.WillMoveToParentViewController : UIKit.UIViewController -> unit


UIViewController UIViewController

The new parent view controller, or null if there won't be a new parent.

This parameter can be null.


Application developers may override this method in their custom container UIViewControllers. Application developers who implement their own container UIViewControllers must call this method with the parent parameter set to null prior to calling RemoveFromParentViewController().

Applies to

See also