DataCommand.Prepare, méthode (String)

Prépare la commande spécifiée dans la source de données à exécuter ; la commande peut ensuite s'exécuter plusieurs fois, dans des paramètres.

Espace de noms :  Microsoft.VisualStudio.Data.Framework
Assembly :  Microsoft.VisualStudio.Data.Framework (dans Microsoft.VisualStudio.Data.Framework.dll)

Syntaxe

'Déclaration
Public Function Prepare ( _
    command As String _
) As String
public string Prepare(
    string command
)
public:
virtual String^ Prepare(
    String^ command
) sealed
abstract Prepare : 
        command:string -> string  
override Prepare : 
        command:string -> string
public final function Prepare(
    command : String
) : String

Paramètres

  • command
    Type : String

    Une commande d'exécution spécifique à une source de données.

Valeur de retour

Type : String
Identificateur de la commande préparée qui peut ensuite être passée à l'Execute ou la méthode ExecuteWithoutResults à l'aide du type de commande Prepared.

Implémentations

IVsDataCommand.Prepare(String)

Exceptions

Exception Condition
ArgumentNullException

Le paramètre command est nullune référence null (Nothing en Visual Basic).

Notes

D'autres exceptions qui se produisent indiquent que la préparation a échoué pour une raison fournisseur- spécifiée.

Sécurité .NET Framework

Voir aussi

Référence

DataCommand Classe

Prepare, surcharge

Microsoft.VisualStudio.Data.Framework, espace de noms

DataCommand