AdoDotNetConnectionProperties.Add Method (String, Type, Object)

Adds a new property to the current connection properties collection.

Namespace:  Microsoft.VisualStudio.Data.Framework.AdoDotNet
Assembly:  Microsoft.VisualStudio.Data.Framework (in Microsoft.VisualStudio.Data.Framework.dll)

Syntax

'Declaration
Public Overridable Sub Add ( _
    key As String, _
    type As Type, _
    value As Object _
)
public virtual void Add(
    string key,
    Type type,
    Object value
)
public:
virtual void Add(
    String^ key, 
    Type^ type, 
    Object^ value
)
abstract Add : 
        key:string * 
        type:Type * 
        value:Object -> unit  
override Add : 
        key:string * 
        type:Type * 
        value:Object -> unit
public function Add(
    key : String, 
    type : Type, 
    value : Object
)

Parameters

  • type
    Type: System.Type

    Type of the property being added.

Implements

IVsDataConnectionProperties.Add(String, Type, Object)

Exceptions

Exception Condition
ArgumentNullException

The propertyName parameter is nulla null reference (Nothing in Visual Basic).

NotSupportedException

The connection string is not extensible.

ArgumentException

The property already exists.

.NET Framework Security

See Also

Reference

AdoDotNetConnectionProperties Class

Add Overload

Microsoft.VisualStudio.Data.Framework.AdoDotNet Namespace