Add unit to group
Description
Section titled “Description”Adds Unit to the specified group in Global.
Syntax
Section titled “Syntax”AddUnitToGroup(Byval UnitName as String, Byval UnitType as String, Byval GroupName as String, Byval GroupType as String) as Boolean
Parameters
Section titled “Parameters”UnitName (String)
The name of the unit
UnitType (String)
Type of Unit
- “Computer”
- “User”
- “Printer”
GroupName (String)
The name of the group
GroupType (String)
The type of the group;
- “Calendar”
- “Department”
- “Reinstall”
- “Security”
- “Static”
- “Dynamic_SQL” (Only Unittype=Printer)
- “Dynamic_ADSI” (Only Unittype=Printer)
Return Value
Section titled “Return Value”Boolean. The function returns True if successful, otherwise false.
Example
Section titled “Example”VBScript
Set oCMS = CreateObject("CapaInstaller.SDK")wscript.echo oCMS.SetDefaultManagementPoint("1")Wscript.echo oCMS.AddUnitToGroup("Klient","computer","test","Static")