2022-07-05 11:06:23 +00:00
|
|
|
Function Set-WallPaper($Value){
|
2022-07-06 08:15:52 +00:00
|
|
|
$url = "https://motd.ping-mee.de/wallpaper.png";
|
2022-07-05 11:06:23 +00:00
|
|
|
$wc = New-Object System.Net.WebClient
|
|
|
|
$wc.DownloadFile($url, "C:\temp\wallpaper.png")
|
|
|
|
Invoke-WebRequest $url -OutFile C:\temp\wallpaper.png
|
|
|
|
Set-ItemProperty -path 'HKCU:\Control Panel\Desktop\' -name wallpaper -value $value
|
|
|
|
rundll32.exe user32.dll, UpdatePerUserSystemParameters
|
|
|
|
}
|
|
|
|
|
|
|
|
Set-WallPaper -value "C:\temp\wallpaper.png"
|