'Declaration Public Shadows Function CreateCommand() As BigcommerceCommand
public new BigcommerceCommand CreateCommand()
Return Value
A BigcommerceCommand object.
'Declaration Public Shadows Function CreateCommand() As BigcommerceCommand
public new BigcommerceCommand CreateCommand()
public void CreateBigcommerceCommand(string myConnString) { BigcommerceConnection bigcommerceConnection = new BigcommerceConnection(myConnString); BigcommerceCommand bigcommerceCommand = bigcommerceConnection.CreateCommand(); bigcommerceCommand.CommandText = "INSERT INTO customers (firstname, lastname, email) VALUES ('John','Smith','[email protected]')"; bigcommerceConnection.Open(); try { bigcommerceCommand.ExecuteNonQuery(); } finally { bigcommerceConnection.Close(); } }
Public Sub CreateBigcommerceCommand(ByVal myConnString As String) Dim bigcommerceConnection As New BigcommerceConnection(myConnString) Dim bigcommerceCommand As BigcommerceCommand = bigcommerceConnection.CreateCommand() bigcommerceCommand.CommandText = "INSERT INTO customers (firstname, lastname, email) VALUES ('John','Smith','[email protected]')" bigcommerceConnection.Open() Try bigcommerceCommand.ExecuteNonQuery() Finally bigcommerceConnection.Close() End Try End Sub