intranet/Intranet/Word_Download/wallpaperchanger2.vbs
2017-03-05 13:52:26 +01:00

14 lines
No EOL
578 B
Text
Executable file

Option Explicit
dim wshShell, sUserName, oShell, oFSO, sWinDir
dim wp
Set wshShell = WScript.CreateObject("WScript.Shell")
sUserName = wshShell.ExpandEnvironmentStrings("admin")
Set oShell = CreateObject("WScript.Shell")
Set oFSO = CreateObject("Scripting.FileSystemObject")
sWinDir = oFSO.GetSpecialFolder(0)
wp(0) = """D:\Programmation\Intranet\Word_Download\scary monsters and nice spirits midi.bmp"""
oShell.RegWrite "HKCU\Control Panel\Desktop\Wallpaper", wp(0)
oShell.Run "d:\WINDOWS\system32\rundll32.exe user32.dll,UpdatePerUserSystemParameters", 1, True