Avatar of jgould763
jgould763
Flag for United States of America asked on

GPO to change default Account User Picture and Default Welcome Screen not working

I'm attempting to create a .bat file that will run as a script from a Windows Server 2008 GPO to Windows 7 computers that will change the default User Account Picture with one from a shared domain server location that has a more corporate theme. First In Group Policy, I enabled the Computer Configuration\Preferences\Control Panel\User Accounts - "Apply the default user logon picture to all users."

I tried a couple of ways to chage the default user.bmp file located at: "%programdata%\Microsoft\User Account Pictures\User.bmp." I tried Computer Configuration\Preferences\Windows Settings\Files\ and replacing the file with one from a shared domain server location without any success.

Second I tried to run a .bat  script, (see script below) but while testing it in the command line, I get the following error: "The system cannot find the path specified. Path not found - C:\ProgramData\Microsoft\User Account Pictures\User.bmp" I suspect it has something to do with permissions, and/or that %programdata% is a hidden folder.

Also, I'm trying to change the default background when users log in. We use BGInfo and I'm trying to change the default login screen to this. I've determined that the file is located at: "%WinDir%\System32\Oobe\background.bmp, but when I try to change it with the script listed below, I get this error: "C:\Windows\System32\Oobe\background.bmp Access is denied. A duplicate file name exists, or the file cannot be found."

I'll admit I'm not any good at this scripting stuff. Maybe there is a better way to do what I'm trying to accomplish. I did find a .vbs file on this site for changing the default User Acount Picture, but I couldn't get it to work. When I run the script in the command line, I get this error: "Input Error: There is no script engine for file extension ".vbs""

Any help would be greatly appreciated.




@echo off
cls

replace \\<SERVER>\BGInfo$\user-image\User.bmp "%programdata%\Microsoft\User Account Pictures\User.bmp" /u

copy %UserProfile%\AppData\Local\Temp\BGInfo.bmp %WinDir%\System32\Oobe /Y
del %WinDir%\System32\Oobe\background.bmp /f /q
rename %WinDir%\System32\Oobe\BGInfo.bmp background.bmp

Open in new window

IT AdministrationWindows Server 2008

Avatar of undefined
Last Comment
gtworek

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
gtworek

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
Experts Exchange is like having an extremely knowledgeable team sitting and waiting for your call. Couldn't do my job half as well as I do without it!
James Murphy