| | |
Changing a background in a batch script
![]() |
Is it possible to set a desktop background using batch? Meaning have a batch file open on start-up and then change the background to a jpeg of my choice? For example, my school's pcs are not set to retain the background after log-off. I always have to set my UNIX background every time I boot up, as does everyone else. I think it would be a nice feature to have a batch script move itself to /startup and then start and change the background.
Toshiba M115 ● 1.49 GB DDR-2 RAM ● 1.6 GHz Centrino Duo ● 80GB HDD ● Windows XP Media Center Edition
go here: http://www.winguides.com/registry/display.php/1097/
they show how to hack the registry to change the background. Be wary of that hack, because I believe it might actually be in: HKEY USERS\ .DEFAULT\Control Panel\Desktop
just remember hacking the registry can result in very bad things happening!
Now just create a simple registry hack ie: background.reg
and place it in the startup folder, you might have to right click the desktop and click refresh for the change to happen
they show how to hack the registry to change the background. Be wary of that hack, because I believe it might actually be in: HKEY USERS\ .DEFAULT\Control Panel\Desktop
just remember hacking the registry can result in very bad things happening!
Now just create a simple registry hack ie: background.reg
and place it in the startup folder, you might have to right click the desktop and click refresh for the change to happen
I don't have access to the registry either. Using the command prompt I can get to the start-up folder, but not by My Computer.
I also shouldn't be able to access the command prompt, but I made a batch script like below, which allows me to open the application.
I also shouldn't be able to access the command prompt, but I made a batch script like below, which allows me to open the application.
command cls
Toshiba M115 ● 1.49 GB DDR-2 RAM ● 1.6 GHz Centrino Duo ● 80GB HDD ● Windows XP Media Center Edition
•
•
Join Date: Jul 2009
Posts: 1
Reputation:
Solved Threads: 0
I know this thread is very old, but it appears no one out there has made this work effectively. I managed to do so today by using the following. Hopefully this helps someone that stumbles upon this on Google:
•
•
•
•
@ECHO OFF
:: Written by Eric Husband
:: 7/10/2009
:: copies the wallpaper from a location into the proper directory and as the proper file name. DO NOT CHANGE THE DESTINATION FILE NAME.
copy "\\ehusband-x1\ERIC\wallpaper1.bmp" "C:\Documents and Settings\%USERNAME%\Local Settings\Application Data\Microsoft\wallpaper1.bmp"
:: Adds the necessary Registry values, in case this person is using a System Wallpaper. If they've already customized their wallpaper, the following lines are not necessary. They won't hurt though.
REG ADD "HKCU\Control Panel\Desktop" /V Wallpaper /T REG_SZ /F /D "C:\Documents and Settings\%USERNAME%\Local Settings\Application Data\Microsoft\wallpaper1.bmp"
:: Change the last number in the following line to a 0 if you want to center the bitmap on the desktop. Change the last number in the following line to a 2 if you want to stretch the bitmap vertically and horizontally to fit the desktop.
REG ADD "HKCU\Control Panel\Desktop" /V WallpaperStyle /T REG_SZ /F /D 2
:: Change the last number in the following line to a 0 to not tile the image; setting it to a 1 Tiles it.
REG ADD "HKCU\Control Panel\Desktop" /V TileWallpaper /T REG_SZ /F /D 0
:: The following line refreshes the desktop.
%SystemRoot%\System32\RUNDLL32.EXE user32.dll, UpdatePerUserSystemParameters
:: The following line Locks the workstation.
%SystemRoot%\System32\RUNDLL32.EXE user32.dll, LockWorkStation
Last edited by Husband; Jul 10th, 2009 at 9:19 pm.
![]() |
Similar Threads
- need help changing background color of an iframe (JavaScript / DHTML / AJAX)
- Closing batch script after .exe is called (Windows NT / 2000 / XP)
- Script or Batch file to load Administrators in XP (Networking Hardware Configuration)
- Batch Script - Error 7901??? (Windows NT / 2000 / XP)
- Automating a script (PHP)
- Bizarre Display Properties Abound (Among other things!) (Viruses, Spyware and other Nasties)
Other Threads in the Windows NT / 2000 / XP Forum
- Previous Thread: Is there a way of forcing Dx8 on a Dx9 game?
- Next Thread: Coloured vertical lines one inch wide on Screen
| Thread Tools | Search this Thread |
.net 3.5 3daccelertion 2007 2010 activedirectory alaris android apache application arm auto black blue book cellphones chinese collaboration combofix computer computerfreezes crash desktop desktops dns domain dotnetnuke drive error errors explorer features folder fontmanagers fonts gadgets hardware intel killprocess laptop laptops latitude lcd linux load mac markshuttleworth microsoft minimalizes mobile monitor netbooks novell nvidia opensource operatingsystems options oracle osinstallationproblem osx outlook partition patch port product proxy raid rds remotedesktopconnection repair screen server. sp1 sp3 spyware studios ubuntu unreadable update upgrade usb verizon videogames virtual virus vista visual vulnerability wab webos weecam win win32/heur window windows windows7 windowsxp windowsxpnotstartingup. worm xp





