Partager via


My Profile Web Part

The My Profile Web Part displays personal information about the shopper. The My Profile Web Part displays the required fields and information in a tabbed view, allowing the user to navigate to data grouped by personal information, shipping information, billing information, and addresses. The tabbed view is not rendered by the My Profile Web Part itself but a control in the ASPX code that houses the Web Part. The Personal Information section allows for editing of attributes such as first name, last name, date of birth, and so on. If you use a unique ID rather than an e-mail address as an identifier on the site, the shopper is able to enter an e-mail address at account creation and edit it later.

The My Profile Web Part is not responsible for creating a new profile, but only for editing an existing profile. The Registration Wizard Web Part creates a new profile. The My Profile Web Part also provides shoppers with a means to manage an account on a Web site by editing their personal information such as first name, last name, date of birth, and so on.

Other sections may be embedded or link from the My Profile section including My List, My Product Reviews, and My Orders.

Architecture

The My Profile Web Part contains these components:

  • MyProfileWebPart: loads user controls dynamically. Derived from BaseUserControlWebPart that encapsulates ASCX loading functionality.

  • MyProfile.ascx User Control: houses the user interface components and corresponding event handlers. This user control displays all the properties of a shopper’s profile such as first name, last name, and date of birth. It also provide validation when attempting to save the shopper’s profile after an edit is made.

Properties

The following table lists the mapping of the properties for the My Profile Web Part.

Property

Maps to

"Allow additional communications" check box text

CheckCommunicationText

"Email" label text

EmailLabelText

Log-in with user name

EnableUserNameAsLogOn

"First name" label text

FirstNameLabelText

"First name is required" message

FirstNameRequiredErrorMessage

Instructional text

InstructionText

"Last name" label text.

LastNameLabelText

"Last name is required" message

LastNameRequiredErrorMessage

"Personal information" section title text

PersonalInformationLabelText

"Personal preferences" section title text

PersonalPreferencesText

"* are required fields" label text

RequiredFieldsText

"Save" button text

SaveButtonText

"Shipping method" label text

ShippingMethodLabelText

"Use Live Id" check box text

UseLiveIDText

"User Id" label text

UserIdLabelText

Customization

You can customize the My Profile Web Part by modifying the MyProfile.ascx user control, including its code-behind.

Error Handling

There is no design-time error handing required for this Web Part.

API Dependencies

The dependencies on the API are:

  • Retrieve properties of the API Profile object

  • Modify properties of the API Profile object

See Also

Other Resources

Profile Administration System Web Parts

Working With the My Profile Web Part