Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Current »

Description

Adds the unit on which the script is executed to the specified Business Unit. UserJobs add user and ComputerJobs add the computer


Syntax

(blue star) CMS_AddUnitToBusinessUnit(sBusinessUnitName) as Boolean

(blue star) [bool]CMS_AddUnitToBusinessUnit -businessunitname <string>


Parameters

sBusinessUnitName (String)

BusinessUnit name


Example

(blue star) VBScript
If bStatus Then bStatus = CMS_AddUnitToBusinessUnit("CapaInstaller")
(blue star) PowerShell
if (CMS_AddUnitToBusinessUnit 'bu_verona') {
  $cs.Job_WriteLog("Added", "Unit added to the Verona Business unit")
}

Scripting Guidelines


Related functions

CMS_RemoveComputerFromDepartmentGroup

  • No labels