Contents Index Topic Contents |
Append Method - ADO
Appends an object to a collection.
Applies To
Syntax
collection.Append object
Parameters
object An object variable representing the object to be appended.
Remarks
Use the Append method on a collection to add an object to that collection. This method is available only on the Parameters collection of a Command object. You must set the Type property of a Parameter object before appending it to the Parameters collection. If you select a variable-length data type, you must also set the Size property to a value greater than zero.
By describing the parameter yourself, you can minimize calls to the provider and consequently improve performance when using stored procedures or parameterized queries. However, you must know the properties of the parameters associated with the stored procedure or parameterized query you wish to call. Use the CreateParameter method to create Parameter objects with the appropriate property settings and use the Append method to add them to the Parameters collection. This lets you set and return parameter values without having to call the provider for the parameter information. If you are writing to a provider that does not supply parameter information, you must manually populate the Parameters collection using this method to be able to use parameters at all.
Examples
Append and CreateParameter Methods Example (VB)
Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.