Skip to content

Commit 5ab6dc1

Browse files
Update Set-CsAutoAttendant.md
edited PR correcting example 3 for callhandlingassociations and callflows as .Remove wont work on powershell 5
1 parent 4c341d3 commit 5ab6dc1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

skype/skype-ps/skype/Set-CsAutoAttendant.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Set-CsAutoAttendant -Instance <Object> [-Tenant <Guid>] [<CommonParameters>]
2424
## DESCRIPTION
2525
The Set-CsAutoAttendant cmdlet lets you modify the properties of an auto attendant. For example, you can change the operator, the greeting, or the menu prompts.
2626

27-
|NOTE|: Please use powershell 7.0 or above, since 7.0 we have started using lists
27+
2828

2929
## EXAMPLES
3030

@@ -95,7 +95,7 @@ $autoAttendant.CallHandlingAssociations
9595
# CallFlowId : e7dd255b-ee20-57f0-8a2b-fc403321e284
9696
# Enabled : True
9797
98-
$autoAttendant.CallHandlingAssociations.Remove(($autoAttendant.CallHandlingAssociations | where-object {$_.ScheduleId -eq "578745b2-1f94-4a38-844c-6bf6996463ee"}))
98+
$autoAttendant.CallHandlingAssociations = $autoAttendant.CallHandlingAssociations | where-object {$_.ScheduleId -ne "578745b2-1f94-4a38-844c-6bf6996463ee"}
9999
100100
$autoAttendant.CallFlows
101101
@@ -109,7 +109,7 @@ $autoAttendant.CallFlows
109109
# Greetings :
110110
# Menu : Christmas Menu
111111
112-
$autoAttendant.CallFlows.Remove(($autoAttendant.CallFlows | where-object {$_.Id -eq "8ab460f0-770c-4d30-a2ff-a6469718844f"}))
112+
$autoAttendant.CallFlows = $autoAttendant.CallFlows | where-object {$_.Id -ne "8ab460f0-770c-4d30-a2ff-a6469718844f"}
113113
114114
Set-CsAutoAttendant -Instance $autoAttendant
115115
```

0 commit comments

Comments
 (0)