Microsoft Operations Manager |
The NextReplicationPartnermethod gets the next replication partner for the domain controller.
[VBScript]
ActiveDirectory.NextReplicationPartner()
None
String
The following example shows how to enumerate the replication partners for a domain controller.
[VBScript]
Function GetPartners()
Dim objActiveDirectory
Dim strReplicationPartner
Dim intIndex
Dim arrPartners()
intIndex = 0
Set objActiveDirectory =
CreateObject("McActiveDir.ActiveDirectory")
If (objActiveDirectory.RefreshReplicationPartners()) Then
strReplicationPartner =
objActiveDirectory.NextReplicationPartner()
While NOT(strReplicationPartner = "")
ReDim Preserve arrPartners(intIndex)
arrPartners(intIndex) = strReplicationPartner
intIndex = intIndex + 1
strReplicationPartner =
objActiveDirectory.NextReplicationPartner()
Wend
End If
Set objActiveDirectory = Nothing
GetPartners = arrPartners
End Function
Windows NT/2000: Requires Windows 2000 or later
Version: Requires MOM 1.0 SP1
Did you find this information useful? Please send your suggestions and comments about the documentation to momsdk@microsoft.com.