Leggere in inglese

Condividi tramite


DataConnectionProperties.AddProperty Method

Definition

Overloads

AddProperty(PropertyDescriptor, Attribute[])

Dynamically adds a new property to the collection of properties natively recognized by the current instance of the DataConnectionProperties class.

AddProperty(String, Type, Attribute[])

Dynamically adds a new property to the collection of properties natively recognized by this data connection properties instance.

AddProperty(PropertyDescriptor, Attribute[])

Dynamically adds a new property to the collection of properties natively recognized by the current instance of the DataConnectionProperties class.

protected:
 System::ComponentModel::PropertyDescriptor ^ AddProperty(System::ComponentModel::PropertyDescriptor ^ descriptor, ... cli::array <Attribute ^> ^ attributes);

Parameters

descriptor
PropertyDescriptor

A PropertyDescriptor object that provides a description of this property and its characteristics.

attributes
Attribute[]

A set of attributes to apply to the property.

Returns

The descriptor of the newly added property.

Exceptions

The descriptor parameter is null.

The specified property already exists.

Applies to

Visual Studio SDK 2022 e altre versioni
Prodotto Versioni
Visual Studio SDK 2017, 2019, 2022

AddProperty(String, Type, Attribute[])

Dynamically adds a new property to the collection of properties natively recognized by this data connection properties instance.

protected:
 System::ComponentModel::PropertyDescriptor ^ AddProperty(System::String ^ name, Type ^ type, ... cli::array <Attribute ^> ^ attributes);

Parameters

name
String

The property name.

type
Type

The data type of the property.

attributes
Attribute[]

A set of attributes to attach to the property.

Returns

The descriptor of the newly added property.

Exceptions

The name and/or type parameters are null.

The specified property already exists.

Applies to

Visual Studio SDK 2022 e altre versioni
Prodotto Versioni
Visual Studio SDK 2017, 2019, 2022