Redigera

Dela via


EntityParameterCollection.Add Method

Definition

Overloads

Add(EntityParameter)

Adds the specified EntityParameter object to the EntityParameterCollection.

Add(Object)

Adds the specified object to the EntityParameterCollection.

Add(String, DbType)

Adds a EntityParameter to the EntityParameterCollection given the parameter name and the data type.

Add(String, DbType, Int32)

Adds a EntityParameter to the EntityParameterCollection with the parameter name, the data type, and the column length.

Add(EntityParameter)

Adds the specified EntityParameter object to the EntityParameterCollection.

public:
 System::Data::EntityClient::EntityParameter ^ Add(System::Data::EntityClient::EntityParameter ^ value);
public System.Data.EntityClient.EntityParameter Add (System.Data.EntityClient.EntityParameter value);
override this.Add : System.Data.EntityClient.EntityParameter -> System.Data.EntityClient.EntityParameter
Public Function Add (value As EntityParameter) As EntityParameter

Parameters

value
EntityParameter

The EntityParameter to add to the collection.

Returns

A new EntityParameter object.

Exceptions

The EntityParameter specified in the value parameter is already added to this or another EntityParameterCollection.

The parameter passed was not a EntityParameter.

The value parameter is null.

Applies to

Add(Object)

Adds the specified object to the EntityParameterCollection.

public:
 override int Add(System::Object ^ value);
public override int Add (object value);
override this.Add : obj -> int
Public Overrides Function Add (value As Object) As Integer

Parameters

value
Object

An Object.

Returns

The index of the new EntityParameter object.

Applies to

Add(String, DbType)

Adds a EntityParameter to the EntityParameterCollection given the parameter name and the data type.

public:
 System::Data::EntityClient::EntityParameter ^ Add(System::String ^ parameterName, System::Data::DbType dbType);
public System.Data.EntityClient.EntityParameter Add (string parameterName, System.Data.DbType dbType);
override this.Add : string * System.Data.DbType -> System.Data.EntityClient.EntityParameter
Public Function Add (parameterName As String, dbType As DbType) As EntityParameter

Parameters

parameterName
String

The name of the parameter.

dbType
DbType

One of the DbType values.

Returns

A new EntityParameter object.

Applies to

Add(String, DbType, Int32)

Adds a EntityParameter to the EntityParameterCollection with the parameter name, the data type, and the column length.

public:
 System::Data::EntityClient::EntityParameter ^ Add(System::String ^ parameterName, System::Data::DbType dbType, int size);
public System.Data.EntityClient.EntityParameter Add (string parameterName, System.Data.DbType dbType, int size);
override this.Add : string * System.Data.DbType * int -> System.Data.EntityClient.EntityParameter
Public Function Add (parameterName As String, dbType As DbType, size As Integer) As EntityParameter

Parameters

parameterName
String

The name of the parameter.

dbType
DbType

One of the DbType values.

size
Int32

The column length.

Returns

A new EntityParameter object.

Applies to