Remove-RDMPlaylistLocal

Synopsis

Delete local playlists.

Syntax

Name

Remove-RDMPlaylistLocal [-Name] <string[]> [-PassThru] [-ForcePromptAnswer <DialogResult[]>]
 [-WhatIf] [-Confirm] [<CommonParameters>]

InputObject

Remove-RDMPlaylistLocal [-InputObject] <PSPlaylistLocal[]> [-PassThru]
 [-ForcePromptAnswer <DialogResult[]>] [-WhatIf] [-Confirm] [<CommonParameters>]

Description

Delete one or more local playlists from the current data source.

Examples

Example 1

PS C:\> Remove-RDMPlaylistLocal -Name 'OldPlaylist'

Deletes the local playlist named 'OldPlaylist'.

Example 2

PS C:\> Remove-RDMPlaylistLocal -Name 'Playlist1', 'Playlist2', 'Playlist3'

Deletes multiple local playlists by name.

Example 3

PS C:\> $playlists = Get-RDMPlaylistLocal
    PS C:\> $filteredPlaylists = $playlists | Where-Object {$_.ConnectionPlayList.Name -like 'Test*'}
    PS C:\> Remove-RDMPlaylistLocal -InputObject $filteredPlaylists -Confirm

Deletes all local playlists whose names start with 'Test', prompting for confirmation on each.

Example 4

PS C:\> $deleted = Remove-RDMPlaylistLocal -Name 'TempPlaylist' -PassThru

Deletes a playlist and returns the deleted playlist object.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type: System.Management.Automation.SwitchParameter
DefaultValue: False
SupportsWildcards: false
Aliases:
- cf
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-ForcePromptAnswer

Switch to use with caution. It will automatically answer prompt asking yes/no, yes/no/cancel, or ok/cancel questions. In case of multiple prompts, multiple values can be passed to this parameter. Here are the accepted values:

  • Yes: Accept the prompt. Cover the OK and Automatic value.

  • No: Refuse the yes/no/cancel prompt. "Cancel" is the fallback option if there is no "No" option.

  • Cancel: Cancel the yes/no/cancel prompt. "No" is the fallback option if there is no "Cancel" option.

Type: System.Windows.Forms.DialogResult[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-InputObject

Local playlist objects to delete.

Type: RemoteDesktopManager.PowerShellModule.PSOutputObject.PSPlaylistLocal[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: InputObject
  Position: 0
  IsRequired: true
  ValueFromPipeline: true
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Name

Names of the local playlists to delete.

Type: System.String[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Name
  Position: 0
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-PassThru

Return the deleted playlist objects.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type: System.Management.Automation.SwitchParameter
DefaultValue: False
SupportsWildcards: false
Aliases:
- wi
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

System.String

Names of playlists to delete.

RemoteDesktopManager.PowerShellModule.PSOutputObject.PSPlaylistLocal

Local playlist objects from Get-RDMPlaylistLocal.

RemoteDesktopManager.PowerShellModule.PSOutputObject.PSPlaylistLocal[]

Outputs

RemoteDesktopManager.PowerShellModule.PSOutputObject.PSPlaylistLocal

Notes

For more information, type "Get-Help Remove-RDMPlaylistLocal -detailed". For technical information, type "Get-Help Remove-RDMPlaylistLocal -full".

Devolutions Forum logo Share your feedback