Scenario
Domain1 and Domain2 have a trust
relationship where Domain2 is the trusted
domain of Domain1. You want to cancel
this trust relationship.
Assumptions
Domain1 is a trusted domain of the domain where the sample script will run.
The user under whose context the script will run has administrative rights on Domain2.
Procedure
Use the RemoveTrust method of
IDomainTrustManagement interface to
delete the existing trust relationship between the two domains.
Script
Dim Trust As IDomainTrustManagement
'Get the interface.
Set Trust = GetObject ("NTDS://Domain1")
'Remove trust relationship with Domain2
Trust.RemoveTrust "Domain2"
See Also