# Retrieve the path of the current desktop background from the registry $wallpaperPath = (Get-ItemProperty -Path "HKCU:\Control Panel\Desktop" -Name WallPaper).WallPaper # Display the wallpaper path Write-Output "The current desktop background is located at: $wallpaperPath" HKEY_CURRENT_USER\Control Panel\Desktop