Determines whether the NameValueCollection contains the specified String key.

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

Syntax

C#
public bool ContainsKey(
	string key
)
Visual Basic
Public Function ContainsKey ( 
	key As String
) As Boolean

Parameters

key
Type: System..::..String
The String key to locate in the NameValueCollection.

Return Value

Type: Boolean
true if the NameValueCollection contains an element with the specified key; otherwise, false.

Remarks

Please refer to ContainsKey(Object) for details but note that the NameValueCollection requires linear time to locate a key.

Exceptions

ExceptionCondition
System..::..ArgumentNullExceptionkey is a null reference.

See Also