次の方法で共有


DataConnectionCollection.Count プロパティ

コレクションに含まれている DataConnection オブジェクトの数を取得します。

名前空間: Microsoft.Office.InfoPath
アセンブリ: Microsoft.Office.InfoPath (microsoft.office.infopath.dll 内)

構文

'宣言
Public MustOverride ReadOnly Property Count As Integer
'使用
Dim instance As DataConnectionCollection
Dim value As Integer

value = instance.Count
public abstract int Count { get; }

プロパティ値

コレクションに含まれている DataConnection オブジェクトの数。

コメント

このメンバは制限なしでアクセスできます。

この型またはメンバは、Microsoft Office InfoPath 2007 または Web ブラウザで開いているフォームで実行されているコードからのみアクセスできます。

次の例では、DataConnection オブジェクトの数がメッセージ ボックスに表示されます。

MessageBox.Show("Count: " + this.DataConnections.Count.ToString());
MessageBox.Show("Count: " & Me.DataConnections.Count.ToString())

関連項目

参照

DataConnectionCollection クラス
DataConnectionCollection のメンバ
Microsoft.Office.InfoPath 名前空間