Export (0) Print
Expand All

EntityParameter Constructor (String, DbType)

Initializes a new instance of the EntityParameter class that uses the parameter name and the data type.

Namespace:  System.Data.EntityClient
Assembly:  System.Data.Entity (in System.Data.Entity.dll)

public EntityParameter(
	string parameterName,
	DbType dbType
)

Parameters

parameterName
Type: System.String

The name of the parameter to map.

dbType
Type: System.Data.DbType

One of the DbType values.

ExceptionCondition
ArgumentException

The value supplied in the dbType parameter is an invalid back-end data type.

The data type and, if appropriate, size and precision are inferred from the value of the dbType parameter.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5 SP1

Community Additions

ADD
Show:
© 2014 Microsoft