System.Windows.Forms.Control.ControlCollection.Remove C# (CSharp) Method

Remove() public method

public Remove ( Control value ) : void
value Control
return void
			public virtual void Remove (Control value)
			{
				if (value == null)
					return;
				
				all_controls = null;
				list.Remove (value);
				
				owner.PerformLayout (value, "Parent");
				owner.OnControlRemoved (new ControlEventArgs (value));
				
				//ContainerControl container = owner.InternalGetContainerControl ();
				//if (container != null) { 
				// Inform any container controls about the loss of a child control
				// so that they can update their active control
				//	container.ChildControlRemoved (value);
				//}
				
				value.ChangeParent (null);
				
				//owner.UpdateChildrenZOrder();
			}

Usage Example

Example #1
0
    public void RemoveFingerprintEvent(System.Windows.Forms.Control.ControlCollection Controls)
    {
        Controls.Remove(m_zkFprint);

        m_currentOnCapture       = null;
        m_currentOnImageReceived = null;
        m_currentOnFeatureInfo   = null;
        m_currentOnEnroll        = null;
        m_zkFprint.CancelCapture();
        m_zkFprint.CancelEnroll();
    }
All Usage Examples Of System.Windows.Forms.Control.ControlCollection::Remove