SqlCeParameterCollection Class
Visual Studio 2010
Collects all parameters relevant to a SqlCeCommand as well as their respective mappings to DataSet columns.
System::Object
System::MarshalByRefObject
System.Data.Common::DbParameterCollection
System.Data.SqlServerCe::SqlCeParameterCollection
System::MarshalByRefObject
System.Data.Common::DbParameterCollection
System.Data.SqlServerCe::SqlCeParameterCollection
Namespace: System.Data.SqlServerCe
Assembly: System.Data.SqlServerCe (in System.Data.SqlServerCe.dll)
The SqlCeParameterCollection type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | Count | Gets the number of SqlCeParameter objects in the collection. (Overrides DbParameterCollection::Count.) |
![]() | IsFixedSize | Infrastructure. (Overrides DbParameterCollection::IsFixedSize.) |
![]() | IsReadOnly | Infrastructure. (Overrides DbParameterCollection::IsReadOnly.) |
![]() | IsSynchronized | Infrastructure. (Overrides DbParameterCollection::IsSynchronized.) |
![]() | Item[Int32] | Gets or sets the SqlCeParameter at the specified index. |
![]() | Item[String] | Gets or sets the SqlCeParameter with the specified name. |
![]() | SyncRoot | Infrastructure. (Overrides DbParameterCollection::SyncRoot.) |
| Name | Description | |
|---|---|---|
![]() | Add(Object) | Adds a SqlCeParameter object to the SqlCeCommand. (Overrides DbParameterCollection::Add(Object).) |
![]() | Add(SqlCeParameter) | Adds the specified SqlCeParameter to the SqlCeParameterCollection. |
![]() | Add(String, SqlDbType) | Adds a SqlCeParameter to the SqlCeParameterCollection given the parameter name and data type. |
![]() | Add(String, Object) | Obsolete. Adds a SqlCeParameter to the SqlCeParameterCollection given the parameter name and value. |
![]() | Add(String, SqlDbType, Int32) | Adds a SqlCeParameter to the SqlCeParameterCollection given the parameter name, data type, and column width. |
![]() | Add(String, SqlDbType, Int32, String) | Adds a SqlCeParameter to the SqlCeCommand given the parameter name, data type, column width, and source column name. |
![]() | AddRange | Adds an array of SqlCeParameter objects to SqlCeParameterCollection. (Overrides DbParameterCollection::AddRange(Array).) |
![]() | AddWithValue | Adds a new SqlCeParameter to the SqlCeParameterCollection and sets its value. |
![]() | Clear | Removes all items from the collection. (Overrides DbParameterCollection::Clear().) |
![]() | Contains(Object) | Gets a value indicating whether or not a SqlCeParameter object exists in the collection. (Overrides DbParameterCollection::Contains(Object).) |
![]() | Contains(String) | Gets a value indicating whether a SqlCeParameter with the specified parameter name exists in the collection. (Overrides DbParameterCollection::Contains(String).) |
![]() | CopyTo | Copies SqlCeParameter objects from the SqlCeParameterCollection to the specified array. (Overrides DbParameterCollection::CopyTo(Array, Int32).) |
![]() | CreateObjRef | (inherited from MarshalByRefObject) |
![]() | Equals | (inherited from Object) |
![]() | Finalize | (inherited from Object) |
![]() | GetEnumerator | Infrastructure. (Overrides DbParameterCollection::GetEnumerator().) |
![]() | GetHashCode | (inherited from Object) |
![]() | GetLifetimeService | (inherited from MarshalByRefObject) |
![]() | GetParameter(Int32) | (inherited from DbParameterCollection) |
![]() | GetParameter(String) | (inherited from DbParameterCollection) |
![]() | GetType | (inherited from Object) |
![]() | IndexOf(Object) | Gets the location of the SqlCeParameter object in the collection. (Overrides DbParameterCollection::IndexOf(Object).) |
![]() | IndexOf(String) | Gets the location of the SqlCeParameter in the collection with the specified parameter name. (Overrides DbParameterCollection::IndexOf(String).) |
![]() | InitializeLifetimeService | (inherited from MarshalByRefObject) |
![]() | Insert | Inserts a SqlCeParameter in the collection at the specified index. (Overrides DbParameterCollection::Insert(Int32, Object).) |
![]() | MemberwiseClone() | (inherited from Object) |
![]() | MemberwiseClone(Boolean) | (inherited from MarshalByRefObject) |
![]() | Remove | Removes the specified SqlCeParameter from the collection. (Overrides DbParameterCollection::Remove(Object).) |
![]() | RemoveAt(Int32) | Removes the SqlCeParameter at the specified index from the collection. (Overrides DbParameterCollection::RemoveAt(Int32).) |
![]() | RemoveAt(String) | Removes the SqlCeParameter with the specified name from the collection. (Overrides DbParameterCollection::RemoveAt(String).) |
![]() | SetParameter(Int32, DbParameter) | (inherited from DbParameterCollection) |
![]() | SetParameter(String, DbParameter) | (inherited from DbParameterCollection) |
![]() | ToString | (inherited from Object) |
| Name | Description | |
|---|---|---|
![]() ![]() | IList::Item | (inherited from DbParameterCollection) |
![]() ![]() | IDataParameterCollection::Item | (inherited from DbParameterCollection) |
The following example creates multiple instances of SqlCeParameter through the SqlCeParameterCollection collection within the SqlCeDataAdapter. These parameters are used to select data within the data source. Then they place the data in the DataSet. This example assumes that a DataSet and a SqlCeDataAdapter have already been created with the appropriate schema, commands, and connection.
Show:

