Get Desktop Dir
Last Modified: June 29, 2023 14:22 CEST

Get-DesktopDir #

SYNOPSIS #

Returns the path to the desktop

SYNTAX #

Get-DesktopDir [<CommonParameters>]

DESCRIPTION #

Returns the path to the desktop of the logged in user. The path does not contain a terminating backslash.

EXAMPLES #

Example 1:Returns the path to the desktop #

PS C:\> Get-DesktopDir
# Output

C:\Users\JohnDoe\Desktop

Returns the path to the desktop for the user John Dow.

PARAMETERS #

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 #

None #

OUTPUTS #

System.Object #

NOTES #

Get-TempDir