Function Set-WallPaper($Value){ Invoke-WebRequest "https://motd.ping-mee.de/wallpaper.png" -OutFile "$($value)wallpaper.png" Set-ItemProperty -path 'HKCU:\Control Panel\Desktop\' -name wallpaper -value "$($value)wallpaper.png" rundll32.exe user32.dll, UpdatePerUserSystemParameters } Set-WallPaper -value "C:\temp\"