ArcGIS Explorer Component Help |
RunWorkerCompletedEventArgs..::.Cancelled Property |
RunWorkerCompletedEventArgs Class See Also |
Gets a value indicating whether the BackgroundWorker was asked to cancel its work.
Namespace:
ESRI.ArcGISExplorer.ThreadingAssembly: ESRI.ArcGISExplorer (in ESRI.ArcGISExplorer.dll) Version: 2.0.0.1500 (2.0.0.1500)
Syntax
C# |
---|
public bool Cancelled { get; } |
Visual Basic (Declaration) |
---|
Public ReadOnly Property Cancelled As Boolean |
Field Value
trueTruetruetrue (True in Visual Basic) if asked to cancel; otherwise, falseFalsefalsefalse (False in Visual Basic).Remarks
Calling the CancelAsync()()()method on a BackgroundWorker which is currently working (IsBusy is trueTruetruetrue (True in Visual Basic)) gives the BackgroundWorker a chance to stop its work and exit the DoWork method. If CancelAsync was called, then the Cancelled property of the RunWorkerCompleted event for that BackgroundWorker will be trueTruetruetrue (True in Visual Basic); this provides an opportunity to report the cancellation on the UI thread after the DoWork method has returned.