Activates a pending membership account.
Assembly: WebMatrix.WebData (in WebMatrix.WebData.dll)
You can require users to confirm their membership before their account is active. To do this, when you create the user account, you call the SimpleMembershipProvider.CreateAccount(String, String, Boolean) or SimpleMembershipProvider.CreateUserAndAccount(String, String, Boolean, IDictionary<String, Object>) method and pass a value that specifies that you want to require confirmation. These methods return a token that uniquely represents the user. You typically construct a hyperlink that points to a confirmation page in your application and that includes the token as a query-string parameter in the link URL. You then send the link to the user in email.
When the user clicks the link, the link invokes your confirmation page. In code for the page, you read the token from the query-string parameter and then call the method. If the token is valid, the user account is confirmed and activated.