The VerifyNoLoops Windows Management Instrumentation (WMI) class method, in Configuration Manager, determines if the insertion of a site in the Configuration Manager hierarchy at a specific point will result in a recursive loop of the sites.
The following syntax is simplified from Managed Object Format (MOF) code and is intended to show the definition of the method.
SInt32 VerifyNoLoops( String CentralSiteCode, String TargetSiteCode, String ParentSiteCode, Boolean Result ); |
Parameters
- CentralSiteCode
- Data type: String Qualifiers: [in, SizeLimit("3")]Not used.
- TargetSiteCode
- Data type: String Qualifiers: [in, SizeLimit("3")]Site code of the child site to insert.
- ParentSiteCode
- Data type: String Qualifiers: [in, SizeLimit("3")] Site code of the site that will be the parent of the target site.
- Result
- Data type: Boolean Qualifiers: [out]true if no loop is formed by inserting the new site in the Configuration Manager hierarchy
Return Values
An SInt32 data type that is 0 to indicate success or non-zero to indicate failure.
For information about handling returned errors, see About Configuration Manager Errors.
Example Code
The following example shows how to call the VerifyNoLoops method.
Copy Code | |
---|---|
Dim Site As SWbemObject Dim NoLoop As Boolean Set Site = GetObject("winmgmts:root\sms\site_<sitecode>:SMS_Site") Site.VerifyNoLoops "", "<child sitecode>", "<parent sitecode>", NoLoop MsgBox "NoLoop = " & NoLoop |
Requirements
Runtime Requirements
For more information, see Configuration Manager Server Runtime Requirements.
Development Requirements
For more information, see Configuration Manager Server Development Requirements.
See Also
Send comments about this topic to Microsoft.