Partager via


Méthode IDTSEvents.OnQueryCancel

Called at any juncture in task processing where it is feasible to cancel execution. This event is raised by tasks and containers to determine whether they should stop running.

Espace de noms :  Microsoft.SqlServer.Dts.Runtime
Assembly :  Microsoft.SqlServer.ManagedDTS (en Microsoft.SqlServer.ManagedDTS.dll)

Syntaxe

'Déclaration
Function OnQueryCancel As Boolean
'Utilisation
Dim instance As IDTSEvents 
Dim returnValue As Boolean 

returnValue = instance.OnQueryCancel()
bool OnQueryCancel()
bool OnQueryCancel()
abstract OnQueryCancel : unit -> bool
function OnQueryCancel() : boolean

Valeur de retour

Type : System.Boolean
A Boolean that indicates if the task should stop running.

Notes

This event is called by the task to determine if the package wishes the task to cease executing. Because the package gives control to the task to execute and does not terminate tasks randomly, there needs to be a juncture at which the package may inform the task that it is attempting to shut down. If the value is true, the task should shut down and a cancelled message is returned from the Execute method of the task. If the value is false, the task continues to run as usual.

Voir aussi

Référence

IDTSEvents Interface

Espace de noms Microsoft.SqlServer.Dts.Runtime