Previous in Contents Next in Contents

Enum Method

This method lists the global properties for the Content Deployment service.

Syntax

ReplicationServer.Enum(Iterator, ParamName)

Parameters

Iterator

Used by the service to enumerate the list of properties. This value should be initialized to zero, and should not be modified.

ParamName

Used by the service to enumerate the names of the properties. This value should be initialized to an empty string, "", and should not be modified.

Remarks

You must have Site Server Publishing administrator privileges on the server to call this method.

For a list of properties that can be retrieved from the Content Deployment service, see Global Properties.

Example

The following example displays the names and values of the service properties.

Option Explicit 
On Error Resume Next 

const CRS_ERROR_NO_MORE_ITEMS  = 0&80003B17

dim ReplServer
set ReplServer = CreateObject("CrsApi.ReplicationServer")
ReplServer.Initialize("")

dim ParamName
ParamName = ""
dim ParamValue
dim Iterator
Iterator = 0
dim ReplError

do while True
  'Clear any error text
  Err.Clear

  ParamValue = ReplServer.Enum(Iterator, ParamName)

  'Quit if "No more items" error 

  ReplError = Err.Number
  if ReplError = CRS_ERROR_NO_MORE_ITEMS then exit do

  Wscript.Echo "Parameter " & ParamName & " = " & ParamValue
Loop
'Release Server object
set ReplServer = Nothing

See Also

EnumProjects, EnumReplications, EnumRoutes


© 1997-2000 Microsoft Corporation. All rights reserved.