Changing Wallpaper through the registry instantly

M

MCsonic

I would like to know the proper batch file parameters to use in order to
change my desktop/wallpaper background instantly. As of now my batch fill
reads:

reg add hkcu\controlpanel\desktop /v wallpaper /t reg_sz /f /d C:\documents
and settings\<username>\local settings\application
data\microsoft\wallpaper.bmp

reg add hkcu\controlpanel\desktop /v wallpaperstyle /t reg_sz /f /d 0

reg add hkcu\controlpanel\desktop /v tilewallpaper /t reg_sz /f /d 2

::make the changes effective immediately
windows\system32\rundll32.exe user32.dll, updateperusersystemparameters

when i run it, nothing happens. Also the echo in the script tells me that
there are to many parameters in the request.

I feel I'm close but i cant seem to get over the hump.

Thanks
 
M

MCsonic

thanks John....

would i just add that to the end of my batch script or would i run that
manually form start>run
 
J

John John (MVP)

Put it at the end of the script or batch file, it has to run *after* the
changes are made to registry.

John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top