Hi All,
I have a Samba PDC and I want all workstations (XP Pro & W2K Pro) to use the same wallpaper.
Is there a way in Samba to force the clients to use a specific wallpaper?
Or do I have to use the logon script for this?

Code: Select all
logon script = logon.bat
[netlogon]
path = /home/netlogon/
browseable = No
read only = yes
Code: Select all
\\ip_address_of_pdc\netlogon\wall.vbs
Code: Select all
' Create the variables needed
Dim WSHShell
Dim strRegKey
Dim strWallpaper
Dim strDesktop
Set shell = CreateObject("WScript.Shell")
Set env = shell.Environment("process")
userpath = env("USERPROFILE")
' msgbox userpath
' Create the Wscript Shell object
Set WSHShell = WScript.CreateObject("WScript.Shell")
' Define the wallpaper
strWallpaper = userpath & "\wall.bmp"
strDesktop = WSHShell.SpecialFolders("Desktop")
' Create the wallpaper key
'strRegKey = "HKEY_CURRENT_USER\"
'strRegKey = strRegKey & "Software\"
'strRegKey = strRegKey & "Microsoft\"
'strRegKey = strRegKey & "Internet Explorer\"
'strRegKey = strRegKey & "Desktop\"
'strRegKey = strRegKey & "General\"
'strRegKey = strRegKey & "Wallpaper"
strRegKey = "HKEY_CURRENT_USER\Control Panel\Desktop\Wallpaper"
' msgbox strRegKey
' msgbox strWallpaper
' Write the key, type, and value
WSHShell.RegWrite strRegKey, strWallpaper, "REG_EXPAND_SZ"
' Refresh the desktop now.
WSHShell.AppActivate strDesktop
WSHShell.SendKeys "{F5}"
'Quit
Wscript.quit(0)
Code: Select all
:: Configure Wallpaper
REG ADD "HKCU\Control Panel\Desktop" /V Wallpaper /T REG_SZ /F /D "%SystemRoot%\wallpaper.bmp"
REG ADD "HKCU\Control Panel\Desktop" /V WallpaperStyle /T REG_SZ /F /D 0
REG ADD "HKCU\Control Panel\Desktop" /V TileWallpaper /T REG_SZ /F /D 2
:: Configure the screen saver.
REG ADD "HKCU\Control Panel\Desktop" /V SCRNSAVE.EXE /T REG_SZ /F /D "%SystemRoot%\System32\scrnsave.scr"
REG ADD "HKCU\Control Panel\Desktop" /V ScreenSaveActive /T REG_SZ /F /D 1
:: Set the time out to 900 seconds (15 minutes).
REG ADD "HKCU\Control Panel\Desktop" /V ScreenSaveTimeOut /T REG_SZ /F /D 900
:: Set the On resume, password protect box
REG ADD "HKCU\Control Panel\Desktop" /V ScreenSaverIsSecure /T REG_SZ /F /D 1
:: Remove the user's ability to see the Screen Saver, background, and appearance tabs of Display Properties.
REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System" /V NoDispScrSavPage /T REG_DWORD /F /D 1
REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System" /V NoDispBackgroundPage /T REG_DWORD /F /D 1
REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System" /V NoDispAppearancePage /T REG_DWORD /F /D 1
:: Make the changes effective immediately
%SystemRoot%\System32\RUNDLL32.EXE user32.dll, UpdatePerUserSystemParametersCode: Select all
REG ADD "HKCU\Control Panel\Desktop" /V Wallpaper /T REG_SZ /F /D [b]"wallpaper.bmp"[/b]