Save-DokuAttachment

SYNOPSIS

Returns the binary data of a media file

SYNTAX

Save-DokuAttachment [-FullName] <String[]> [[-Path] <String>] [-Force] [-WhatIf] [-Confirm]
 [<CommonParameters>]

DESCRIPTION

Returns the binary data of a media file and save to a file

EXAMPLES

EXAMPLE 1

Save-DokuAttachment -FullName 'study:picture.jpg' -Path 'C:\picture.jpg'

Downloads the file picture.jpg from the study namespace and saves to the root of the C drive with the given name

EXAMPLE 2

Save-DokuAttachment -FullName 'study:picture.jpg' -Path 'C:\picture.jpg' -Force

As above, but overwrites any exisitng files with the same name

PARAMETERS

-Force

Force creation of output file, overwriting any existing files with the same name

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: 3
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-FullName

The full name of the file to get

Type: String[]
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByPropertyName, ByValue)
Accept wildcard characters: False

-Path

The path to save the attachment to, including filename & extension

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-WhatIf

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

Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

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

INPUTS

OUTPUTS

System.IO.FileInfo

NOTES

AndyDLP - 2018-05-26

https://github.com/AndyDLP/PSDokuWiki