AllForms.Count 屬性 (Access)

使用 Count 屬性判斷指定集合中的項目數。 唯讀的 Long。

語法

運算式。計數

運算式 代表 AllForms 物件的變數。

範例

例如,如果您想要判斷目前開啟或資料庫上現有表單的數目,您可以使用下列程式碼字串。

' Determine the number of open forms. 
 
forms.count 
 
' Determine the number of forms (open or closed) 
' in the current database. 
 
currentproject.allforms.count

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應。