OleDbFactory.CreateCommand Methode

Definition

Gibt eine stark typisierte DbCommand-Instanz zurück.

public:
 override System::Data::Common::DbCommand ^ CreateCommand();
public override System.Data.Common.DbCommand CreateCommand ();
override this.CreateCommand : unit -> System.Data.Common.DbCommand
Public Overrides Function CreateCommand () As DbCommand

Gibt zurück

Eine neue stark typisierte DbCommand-Instanz.

Beispiele

Das folgende Codefragment gibt eine stark typisierte DbCommand instance zurück:

Dim newFactory As OleDbFactory = OleDbFactory.Instance
Dim cmd As DbCommand = newFactory.CreateCommand()
OleDbFactory newFactory = OleDbFactory.Instance;
DbCommand cmd = newFactory.CreateCommand();

Gilt für: