Previous in Contents Next in Contents

Enum Method

This method lists the properties of the Posting Acceptor.

Syntax

ReplicationPostingAcceptor.Enum(Iterator, PropName)

Parameters

Iterator

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

PropName

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.

The properties are described in the following table.

Property Description
MaximumOpenTransactions The maximum number of transactions that can be running at the same time.
OpenTransactionsTimeout The time-out duration, in milliseconds.
AllowAnonymous Whether anonymous users can post.
AutoStartReplications Whether replications are automatically started when a new post arrives.
PathToPA The absolute path to the Posting Acceptor directory.
RepostURL The URL on the destination server to which the postings are sent.
TargetURL The URL on the source server from which the postings are sent.

Example

The following example lists the properties of the Posting Acceptor.

const CRS_ERROR_NO_MORE_ITEMS  = 0&80003B17

dim ReplServer
set ReplServer = CreateObject("Crsapi.ReplicationServer")
ReplServer.Initialize("")
dim RepPA
set RepPA = ReplServer.OpenPostingAcceptor

dim PropName
PropName = ""
dim PropVal
dim Iterator
Iterator = 0
dim ReplError

do while True
  'Clear any error text
  Err.Clear

  PropVal = RepPA.Enum(Iterator, PropName)

  'Quit if PropName is empty (no property returned)
  if IsEmpty(PropVal) then exit do

  'Quit if "No more items" error 

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

  Wscript.Echo PropName & " = " & PropVal
Loop

'Release objects
set RepPA      = Nothing
set ReplServer = Nothing

See Also

Get, Put, ReplicationServer.OpenPostingAcceptor


© 1997-2000 Microsoft Corporation. All rights reserved.