# CMS_RemoveComputerFromCalendarGroup

> Removes a specified computer unit from a calendar group.

Source: https://docs.capaone.com/capainstaller/vb-scripting-library/cms-functions/cms-removecomputerfromcalendargroup/  
Product: CapaInstaller — a separate CapaSystems product; do not apply this page to any other.

### Description

Removes a specified computer unit from a calendar group

For Business Unit support click [Business Unit support](/capainstaller/vb-scripting-library/addendum/business-unit-support/)

### Syntax

**VBScript**

```vb
CMS_RemoveComputerFromCalendarGroup(sUnit as String, sGroup as String) as Boolean
```

**PowerShell**

```powershell
[bool] CMS_RemoveComputerFromCalendarGroup -group <string>
```

### Parameters

#### sUnit (String)

Unit name

#### sGroup (String)

Group name

### Return value

**VBScript**

Boolean, TRUE if function completed successfully.

**PowerShell**

Boolean, TRUE if function completed successfully.

### Example

**VBScript**

```vb
If bStatus Then bStatus = CMS_RemoveComputerFromCalendarGroup(gsUnitName, "CapaInstaller")
```

**PowerShell**

```powershell
if (CMS_RemoveComputerToCalendarGroup -group 'calendar1') {
  $cs.Job_WriteLog("Removed", "Computer removed from calendar group: 'calendar1'")
} 
```

[Scripting Guidelines](/capainstaller/vb-scripting-library/scripting-guidelines/)

### Related functions

[CMS_AddComputerToCalendarGroup](/capainstaller/vb-scripting-library/cms-functions/cms-addcomputertocalendargroup/) [Constants](/capainstaller/vb-scripting-library/addendum/constants/) [Package Property](/capainstaller/vb-scripting-library/addendum/package-property/) [Variables](/capainstaller/vb-scripting-library/addendum/variables/) [Business Unit support](/capainstaller/vb-scripting-library/addendum/business-unit-support/)
