共用方式為


ProfileProviderCollection.Item[String] 屬性

定義

傳回指定的提供者名稱所參考的設定檔提供者。

public:
 property System::Web::Profile::ProfileProvider ^ default[System::String ^] { System::Web::Profile::ProfileProvider ^ get(System::String ^ name); };
public System.Web.Profile.ProfileProvider this[string name] { get; }
member this.Item(string) : System.Web.Profile.ProfileProvider
Default Public ReadOnly Property Item(name As String) As ProfileProvider

參數

name
String

設定檔提供者的名稱。

屬性值

ProfileProvider

繼承 ProfileProvider 抽象類別的物件。

備註

應用程式的設定檔提供者會透過 Providers 類別的 ProfileManager 屬性公開為唯讀 ProfileProviderCollection 。 您可以依名稱存取集合中的特定設定檔提供者,並將其轉換成特定提供者類型,例如 SqlProfileProvider 。 這可讓您管理單一應用程式中多個資料存放區的使用者設定檔屬性。 它也可讓您存取不是抽象類別成員的特定設定檔提供者成員 ProfileProvider

適用於

另請參閱