ListFieldCounter Object
Contains information about the key counter used within the list.
This object is supported only by Web pages or sites that are based on Microsoft SharePoint Services.
Remarks
This field is created automatically by Microsoft FrontPage and cannot be modified by the user.
Using the ListFieldCounter object
The following example displays the name associated with the counter field in the current list.
Sub ListCounterFields()
'Displays the name of counter fields in the current list
Dim objApp As FrontPage.Application
Dim objField As ListField
Dim strType As String
Dim blnFound As Boolean
blnFound = False
Set objApp = FrontPage.Application
If Not ActiveWeb.Lists Is Nothing Then
For Each objField In objApp.ActiveWeb.Lists.Item(0).Fields
'Check if it is a computed field of type fpFieldFile
If objField.Type = fpFieldCounter Then
blnFound = True
If strType = "" Then
'Create new string
strType = objField.Name & vbCr
Else
'Add next field name to string
strType = strType & objField.Name & vbCr
End If
End If
Next objField
If blnFound = True Then
MsgBox "The names of the fields in this list are: " & _
vbCr & strType
Else
MsgBox "There are no counter fields in the list."
End If
Else
'Otherwise display message to user
MsgBox "The current web site contains no lists."
End If
End Sub