Μέθοδος Cancel του ADO

Ορισμός και χρήση

Η μέθοδος Cancel μπορεί να ακυρώσει την εκτέλεση της κλήσης της μεθόδου.

Η μέθοδος Cancel μπορεί να τερματίσει διαφορετικές εργασίες για διαφορετικά αντικείμενα. Το παρακάτω πίνακα παρουσιάζει τις εργασίες που τερματίζονται όταν καλούνται αυτή η μέθοδος:

Object Terminated Tasks
Command Execute.

Note: Before the Cancel method is called, the Options parameter of the Execute method must be set to adAsyncExecute or adAsyncFetch, otherwise a run-time error will occur.

Connection Execute or Open.

Note: Before the Cancel method is called, the Options parameter of the Open method must be set to adSyncConnect, and the Options parameter of the Execute method must be set to adAsyncExecute or adAsyncFetch, otherwise a run-time error will occur.

Record CopyRecord, DeleteRecord, MoveRecord, ή Open.
Recordset Open
Stream Open

Syntax

object.Cancel