Add a new attachment to a session
Add-RDMSessionAttachment [-Session] <PSConnection> [-Filename] <string> [-Description <string>]
[-Password <securestring>] [-Refresh] [-Title <string>] [-ForcePromptAnswer <DialogResult[]>]
[<CommonParameters>]
Add a new attachment to a session. Two parameters are required: Filename, path to the file to attach, and Session, where the file is attached. Additional information can be provided via the title and description. The attachment can be protected by a password. Only advanced data sources support attachment. The user must have the permission to add attachments.
PS C:\> $entry = Get-RDMSession -Name EntryA;
Add-RDMSessionAttachment -Filename 'C:\my\path\filename.ext' -Session $entry
Attach the file filename.ext, located in 'C:\my\path', to the session named EntryA.
PS C:\> $entry = Get-RDMSession -Name EntryA;
$password = Read-Host -AsSecureString;
Add-RDMSessionAttachment -Filename 'C:\my\path\filename.ext' -Session $entry -Description 'A description of the attachment' -Title 'Essential' -Password $password -Refresh
Attach the file filename.ext, located in 'C:\my\path', to the session named EntryA. The attachment will be protected by the password entered with Read-Host. Additional information is stored. The refresh parameter will update the RDM UI.
Attachment description.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
Attachment filename.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: 1
IsRequired: true
ValueFromPipeline: true
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
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 not an option No.
Cancel: Cancel the yes/no/cancel prompt. No is the fallback option if there is not an option Cancel.
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: ''
Attachment password.
Type: System.Security.SecureString
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
Send refresh notification to Remote Desktop Manager application.
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: ''
Session to add the attachment to.
Type: RemoteDesktopManager.PowerShellModule.PSOutputObject.PSConnection
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: 0
IsRequired: true
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
Attachment title.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
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.
For more information, type "Get-Help Add-RDMSessionAttachment -detailed". For technical information, type "Get-Help Add-RDMSessionAttachment -full".