Click or drag to resize

DataExtensionsPopulateParametersTDbCommand(TDbCommand, ActionTDbCommand, Object) Method

Takes the IDbCommand object and populates it with the given parameters.

Namespace: GSF.Data
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.218-beta+101eee949414e414795e55a6e73d88938f0177b8
Syntax
public static void PopulateParameters<TDbCommand>(
	this TDbCommand command,
	Action<TDbCommand> deriveParameters,
	Object[] values
)
where TDbCommand : IDbCommand
View Source

Parameters

command  TDbCommand
The IDbCommand whose parameters are to be populated.
deriveParameters  ActionTDbCommand
The DeriveParameters() implementation of the command to use to populate parameters.
values  Object
The parameter values to populate the IDbCommand parameters with.

Type Parameters

TDbCommand
Then IDbCommand type to be used.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type TDbCommand. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Exceptions
ExceptionCondition
ArgumentException Number of IDbDataParameter arguments in CommandText of this command, identified by '@', do not match number of supplied parameter values -or- You have supplied more values than parameters listed for the stored procedure.
See Also