for starters, the script only works once after being executed, so if someone else changes the wallpaper afterwards, you would have to execute the script again
if you want it to be a permanent script, you have to run it at startup, or run a different script at startup to invoke your script every time someone tries to change the wallpaper, and set it up to loop indefinitely
here's how I did it:
1st I made a script based on one I found online:
Sub Run(ByVal sFile)
Dim shell
Set shell = CreateObject("WScript.Shell")
shell.Run Chr(34) & sFile & Chr(34), 1, false
Set shell = Nothing
End Sub
const HKEY_CURRENT_USER = &H80000001
strComputer = "."
Do While true
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" &_
strComputer & "\root\default:StdRegProv")
strKeyPath = "Control Panel\Desktop"
strValueName = "Wallpaper"
oReg.GetStringValue HKEY_CURRENT_USER,strKeyPath,strValueName,strValue
if strValue <> "C:\Private\Wallpaper1.bmp" then
'change that to whatever file and location you got for your own wallpaper
Run "C:\Private\wp.vbs"
'change that last line to whatever is your script's name and location
end if
Loop
2nd, I opened the registry editor (run Regedit) and then went to HKEY_CURRENT_USER\Software\Windows\CurrentVersion\Run
I added a new String value (call it whatever you want), and as the value I typed the full filename of your script (example: C:\Private\wpmonitor.vbs).
Follow the steps above, restart the session, and enjoy! :)
3rd, sadly, you can only change your wallpaper directly to a bmp file using this script (when you do it through the Display Settings menu, Windows does the conversion for you)... there must be a workaround somewhere but I haven't gone in-depth there yet