PersonalizationStateInfoCollection.Count プロパティ

定義

コレクション内の項目の数を取得します。

public:
 property int Count { int get(); };
public int Count { get; }
member this.Count : int
Public ReadOnly Property Count As Integer

プロパティ値

コレクション内の項目数。

実装

次のコード例では、 プロパティの使用方法 Count を示します。

  PersonalizationStateInfoCollection findresult;
findresult = PersonalizationAdministration.FindUserState(null, TextBox3.Text);
if (findresult.Count != 0)
{
    Label4.Text = findresult.Count + "  user(s) found";
    Label4.Visible = true;
}

注釈

この例に示すように、コレクション内の項目の数を使用してコレクションを反復処理できます。

適用対象