System.ComponentModel.Design.IComponentChangeService.ComponentChanged Event

Occurs when a component has been changed.


public event ComponentChangedEventHandler ComponentChanged


This event occurs when any component on the form changes. This event will not occur during form load and unload, because changes are expected at this time.


A System.ComponentModel.Design.DesignerTransaction can raise multiple IComponentChangeService.ComponentChanged events. Some IComponentChangeService.ComponentChanged event handlers can interfere with expected sequences of events, such as if your code alters the values of properties while a transaction is occurring. A IComponentChangeService.ComponentChanged event handler can also impair performance if it draws after each change while a System.ComponentModel.Design.DesignerTransaction is in progress. In order to allow a System.ComponentModel.Design.DesignerTransaction in process to complete without interruption or interference by your IComponentChangeService.ComponentChanged event handler, you can test the state of the IDesignerHost.InTransaction property, and defer handling the change events until the completion of the transaction by adding a System.ComponentModel.Design.DesignerTransactionCloseEventHandler which will raise your IComponentChangeService.ComponentChanged event handler and remove itself upon completion of the transaction.


Namespace: System.ComponentModel.Design
Assembly: System (in System.dll)
Assembly Versions: 1.0.5000.0,,