Επεξεργασία

Κοινή χρήση μέσω


ProfileProviderCollection.Add(ProviderBase) Method

Definition

Adds a profile provider to the collection.

public:
 override void Add(System::Configuration::Provider::ProviderBase ^ provider);
public override void Add (System.Configuration.Provider.ProviderBase provider);
override this.Add : System.Configuration.Provider.ProviderBase -> unit
Public Overrides Sub Add (provider As ProviderBase)

Parameters

provider
ProviderBase

The profile provider to add to the collection.

Exceptions

provider is null.

provider is not of a type that inherits the ProfileProvider abstract class.

Remarks

This method is not intended to be used from your code.

Profile provider instances are added to the ProfileProviderCollection for an application using the providers Element for profile (ASP.NET Settings Schema) section of the profile configuration element. You can access the profile provider collection using the Providers property of the ProfileManager class.

Applies to

See also