This documentation is archived and is not being maintained.

ColumnProvider::AddDefaultAttributes Method

Adds default attributes.

Namespace:  System.Web.DynamicData.ModelProviders
Assembly:  System.Web.DynamicData (in System.Web.DynamicData.dll)

protected:
static AttributeCollection^ AddDefaultAttributes(
	ColumnProvider^ columnProvider, 
	AttributeCollection^ attributes
)

Parameters

columnProvider
Type: System.Web.DynamicData.ModelProviders::ColumnProvider
The column provider.
attributes
Type: System.ComponentModel::AttributeCollection
The attribute collection.

Return Value

Type: System.ComponentModel::AttributeCollection
The attribute collection.

If the attributes parameter does not contain the RequiredAttribute collection, but the model provider requires this attribute, the RequiredAttribute object is added. If the attributes parameter does not contain the StringLengthAttribute collection and the column that is represented by this provider is a string, the StringLengthAttribute object is added.

.NET Framework

Supported in: 4

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show: