Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Batch Script for Changing Desktop Wallpaper and Adding Reg Entries

Posted on 2010-09-23
4
Medium Priority
?
970 Views
Last Modified: 2012-06-27
Hi Guys,

Its Footy Day today (Australian Rules) and my manager wants me to write a script up that will change peoples desktop backgrounds to a picture from a general network folder, and disable the Themes and Desktop Tab from the Display Properties.

These are the 2 keys that will disable the tab's:

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]
"NoThemesTab"=dword:00000001

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System]
"NoDispBackgroundPage"=dword:00000001

A simple Batch Script would be suffice i would assume, ive tried to write my own up though im still quite new to this :(

If i could get one that will also reverse these effects that would be awesome!

Thanks in Advance,

Adrian :)
0
Comment
Question by:Adrian_May
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 

Author Comment

by:Adrian_May
ID: 33750348
Perhaps to clarify, I would not like to give them an option.

I would only like to make a batch that is only going to set one wallpaper for everyone, and remove the ability to change it.

then a reversal script would also be appreciated :)
0
 
LVL 21

Accepted Solution

by:
AmazingTech earned 2000 total points
ID: 33755801
Below code is a batch file. Save it as a .CMD in ANSI format.

Set WallpaperImage="\\Server\Share\Footy Pic Of The Day.bmp"

REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoThemesTab" /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\Control Panel\Desktop" /v Wallpaper /t REG_SZ /f /d %WallpaperImage%

rundll32.exe user32.dll,UpdatePerUserSystemParameters

0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This script will sweep a range of IP addresses (class c only, 255.255.255.0) and report to a log the version of office installed. What it does: 1.)      Creates log file in the directory the script is run from (if it doesn't already exist) 2.)      Sweep…
This article was inspired by a question here at Experts Exchange (http://www.experts-exchange.com/Software/Photos_Graphics/Images_and_Photos/Q_28629170.html). The requirements stated in that question are (1) reduce the file size of a large number of…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question