Visual Basic (Declaration) | |
---|---|
Public Overridable Sub EnableEvents() |
Visual Basic (Usage) | Copy Code |
---|---|
|
C# | |
---|---|
public virtual void EnableEvents() |
C++/CLI | |
---|---|
public: virtual void EnableEvents(); |
The RasterImage maintains an internal count for change events. When the count is 0, the RasterImage.Changed event will be raised whenever the image changes. Calling DisableEvents will increment this internal counter and thus preventing the RasterImage.Changed from being raised.
Each call to DisableEvents should have a corresponding call to EnableEvents in order to restore the raising of events.
If you have multiple operations that change this RasterImage, it is recommended that you surround them with a pair of DisableEvents/EnableEvents call and then just call OnChanged once after you are done.
Target Platforms: Microsoft .NET CF Framework 2.0, Windows Mobile 5 PocketPC, Windows Mobile 5 Smartphone, Windows Mobile 6