This method is used to attach array of IDataParameters to an IDbCommand. This method will assign a value of DbNull to any parameter with a direction of InputOutput and a value of null. This behavior will prevent default values from being used, but this will be the less common case than an intended pure output parameter (derived as InputOutput) where the user provided no input value.

Namespace: CodeSmith.Engine
Assembly: CodeSmith.Engine (in CodeSmith.Engine.dll) Version: 6.0.0.0 (7.0.0.15127)

Syntax

C#
protected virtual void AttachParameters(
	IDbCommand command,
	IDataParameter[] commandParameters
)
Visual Basic
Protected Overridable Sub AttachParameters ( 
	command As IDbCommand,
	commandParameters As IDataParameter()
)

Parameters

command
Type: System.Data..::..IDbCommand
The command to which the parameters will be added
commandParameters
Type: array<System.Data..::..IDataParameter>[]()[][]
An array of IDataParameterParameters to be added to command

Exceptions

ExceptionCondition
System..::..ArgumentNullExceptionThrown if command is null.

See Also