Provides programmatic access to the group subsection of the profiles configuration file section.
Assembly: System.Web (in System.Web.dll)
The class provides a way to programmatically create, access, and modify groups of properties added to the group subsection of the profile section of a configuration file.
The profile section of the configuration file specifies a schema for user profiles. At run time, the ASP.NET compilation system uses the information specified in the profile section to generate a class called ProfileCommon, which is derived from ProfileBase. The ProfileCommon class definition is based on the properties defined in the properties subsection of the profile section of the configuration file. An instance of this class is created for each user profile, and you can access the individual profile values in your code through the HttpContext.Profile property. For more information about the profile features added to ASP.NET 2.0, see ASP.NET Profile Properties Overview.
The following code example shows how to use the type. This code example is part of a larger example provided for the ProfileSection class.
// Add a new group. ProfileGroupSettings newPropGroup = new ProfileGroupSettings("Forum"); profileSection.PropertySettings.GroupSettings.Add(newPropGroup); // Add a new PropertySettings to the group. ProfilePropertySettings newProp = new ProfilePropertySettings("AvatarImage"); newProp.Type = "System.String, System.dll"; newPropGroup.PropertySettings.Add(newProp); // Remove a PropertySettings from the group. newPropGroup.PropertySettings.Remove("AvatarImage"); newPropGroup.PropertySettings.RemoveAt(0); // Clear all PropertySettings from the group. newPropGroup.PropertySettings.Clear();
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.