Export (0) Print
Expand All

ProfilePropertySettings Constructor (String, Boolean, SerializationMode, String, String, String, Boolean, String)

Initializes a new instance of the ProfilePropertySettings class with the specified name and settings.

Namespace:  System.Web.Configuration
Assembly:  System.Web (in System.Web.dll)

public ProfilePropertySettings(
	string name,
	bool readOnly,
	SerializationMode serializeAs,
	string providerName,
	string defaultValue,
	string profileType,
	bool allowAnonymous,
	string customProviderData
)

Parameters

name
Type: System.String

A unique name for the ProfilePropertySettings object.

readOnly
Type: System.Boolean

true to indicate that the associated property in the dynamically generated ProfileCommon class should be read-only; otherwise, false.

serializeAs
Type: System.Web.Configuration.SerializationMode

One of the SerializationMode values.

providerName
Type: System.String

The name of a provider from the Providers property, or an empty string ("").

defaultValue
Type: System.String

A string containing the default value used for the named property in the generated page Profile class.

profileType
Type: System.String

A valid type reference or an empty string.

allowAnonymous
Type: System.Boolean

true to indicate associated property in the dynamically generated ProfileCommon class should support anonymous users; otherwise, false, to indicate that anonymous users cannot change the named property.

customProviderData
Type: System.String

A string containing provider-specific information used by the provider associated with the property.

At run time, the ASP.NET compilation system uses the information specified in the profile section of the configuration file to generate a class called ProfileCommon, which is derived from ProfileBase. The class allows you to access and modify the values for individual user profiles.

The ProfileCommon class definition is based on the properties defined in the properties subsection of the profile section of the configuration file. The parameter values that you specify when you create an instance of the ProfilePropertySettings class will be used to define an associated property in the ProfileCommon class.

For more information about profile properties, see ASP.NET Profile Properties Overview.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0

Community Additions

ADD
Show:
© 2014 Microsoft