Solved

changeing logon screen for everyone, Birthdays!!

Posted on 2014-01-03
14
319 Views
Last Modified: 2014-07-24
i have been wanting to extend my "customer service" so that i can recognize folks in a quiet way for their birthdays, we used to do emails but that became a nusiance for employees when people would hit reply all. what i was trying to do was change the login screen on XP and windows 7 to have an image that says happy birthday when the user goes to login. i found the registry options for windows 7 to change the logon image which is a piece of cake. my boss was hopeing we could set up a central location for the image that we can connect to using symlink. i created the folder containing the BackgroundDefault.jpg image both creating it on my machine and placing it on the machine in question and creating it on that machine in question. when i create the link i am able to browse to it and view the image, but the registry doesnt pick it up, it just goes back to the default image. is there a way to do this that the registry will work. the image location is on my computer in my user folder in a shared folder that has all permissions set to allow annonymous read and execute. so computer a has the image, computer B is liked to it and the registry is aimed in the right direction it just seems to ignore the folder even though the way its set up the folder is considered a folder and not a short cut.

let me know if i need to be more clear. thanks in advance!
0
Comment
Question by:FT-Techs
  • 7
  • 7
14 Comments
 
LVL 14

Expert Comment

by:Giovanni Heward
ID: 39754240
Did you create a symbolic link named backgroundDefault.jpg in the %windir%\System32\Oobe\info\backgrounds folder?

mklink %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg \\server.domain.local\share\path\backgroundDefault.jpg

Open in new window


Two other things to keep in mind: First, the actual file size of backgroundDefault.jpg cannot exceed 256 KB. Second, you'll want to use an image whose dimensions match the screen resolution that you are using. If you use a file whose dimensions are smaller, the image will be stretched and may appear distorted.

So you may want to run a resolution detection process which creates the symlink based on the resolution of the end-user:

mklink %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg \\server.domain.local\share\path\background1024x768.jpg

Open in new window


PowerShell
powershell -ep bypass -c "Get-WmiObject -Class Win32_DesktopMonitor | Select-Object ScreenWidth,ScreenHeight"

Open in new window


VBS
strComputer = "." 
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\CIMV2") 
Set colItems = objWMIService.ExecQuery( _
    "SELECT * FROM Win32_DesktopMonitor",,48) 
For Each objItem in colItems 
    Wscript.Echo "-----------------------------------"
    Wscript.Echo "Win32_DesktopMonitor instance"
    Wscript.Echo "-----------------------------------"
    Wscript.Echo "ScreenHeight: " & objItem.ScreenHeight
    Wscript.Echo "ScreenWidth: " & objItem.ScreenWidth
Next

Open in new window


Both query WMI, as you can see.
0
 

Author Comment

by:FT-Techs
ID: 39754259
system32\oobe\info>mklink /d backgrounds \\(computername)\pictures\backgroundDefault.jpg  

this is what my command prompt looks like, i started at the Info folder and then created the MKlink.  its linked to a folder on my computer.
0
 

Author Comment

by:FT-Techs
ID: 39754267
sorry, i told you wrong, this is what i did
 system32\oobe\info>mklink /d backgrounds \\(computername)\pictures\background
i also tried with the BackgroundDefault.jpg and it didnt recognize the file location with the .jpg
0
 
LVL 14

Expert Comment

by:Giovanni Heward
ID: 39754272
backgrounds needs to be a folder, and within that folder the file backgroundDefault.jpg

My syntax is correct:

mklink %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg \\server.domain.local\share\path\background1024x768.jpg

Here's another method of obtaining the screen resolution using WMIC:

wmic desktopmonitor get screenheight,screenwidth

Open in new window

0
 
LVL 14

Expert Comment

by:Giovanni Heward
ID: 39754278
So create the folder locally, and try a symbolic link on the file rather than folder.  If that fails, you may need to copy all backgrounds to the local machine.  You could have happybday.jpg just sitting there the entire time, and when the target date arrives you simply rename the existing background (to be restored the next day) and rename the happybday.jpg to backgroundDefault.jpg

if not exist %windir%\System32\oobe\info\backgrounds md %windir%\System32\oobe\info\backgrounds

Open in new window


Update:  Just tested with Windows 7 Pro x64 joined to a domain and the symbolic link reference works when backgroundDefault.jpg itself is linked to an accessible share and background image meeting the requirements outlined above.
0
 

Author Comment

by:FT-Techs
ID: 39754315
ok we used your syntax, it got the image over just as we needed. but the registry still doesnt see it.

this is what i did.

C:\Windows\System32\oobe\info>    mklink %windir%\System32\oobe\info\backgrounds\bac
kgroundDefault.jpg
\\(computername.domain)\background\backgroundDefault.jpg
0
 
LVL 14

Expert Comment

by:Giovanni Heward
ID: 39754348
Just to be thorough, let's remove the folder first (to ensure it's not a symlink) and then try again:

rd %windir%\System32\oobe\info\backgrounds /s/q

Open in new window


Then import the following registry file.

OEMBackground.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI\Background]
"OEMBackground"=dword:00000001

Open in new window


Then create the local folder as a folder and not a symbolic link.

md %windir%\System32\oobe\info\backgrounds

Open in new window


Verify the background image file is <= 256 KB

If file size OK, try linking to the image file again.

mklink %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg \\server.domain.local\share\path\background1024x768.jpg

Open in new window

0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:FT-Techs
ID: 39754354
yeah, sorry. just double checked my image, it is over the max size, i changed pictures half way though and forgot to check the new picture. i will try again.
0
 

Author Comment

by:FT-Techs
ID: 39754390
i have a picture that i can place there, that is stored on that machine, as soon as i drop it in the backgrounds folder, i can hit CTR ATL DEL and see the image, then i swap back to the symlinked image and it goes back to the default screen. the only thing that is changing now is the local image with the symlink image. which the symlink image is 43.6 KB my local picture is 98KB. i tried both replacing the symlink image with the local and then replacing it again, only the local image works. i tried deleteing the images and recreating the symlink one in the backgrounds folder with no luck. so it seems the registry is correct cause it will pull an image from the folder. but when i add the symlink image either dragged and dropped in or placed in with the syntax it goes to the default. does it matter that its the location of the original image that is being linked is on my local machine instead of a server? its set so that Anonymous has read and execute on everything in the share i made.
0
 
LVL 14

Expert Comment

by:Giovanni Heward
ID: 39754421
As long as you have an authenticated connection to the file share prior to display of the image, you should be OK.

Try the following, before running through your test above.

net use \\server.domain.local\share

Open in new window


Where server.domain.local is the server hosting the image.

In your actual script to replace the background image, you may want to verify the file exists using the UNC path and local location, prior to continuing.  This will create the network connection in the background.

if exist \\server.domain.local\share\path\backgroundDefault.jpg (
   if exist %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg del %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg 
   mklink %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg \\server.domain.local\share\path\backgroundDefault.jpg
if exist %windir%\System32\oobe\info\backgrounds\backgroundDefault.jpg echo good to go!
)

Open in new window

0
 
LVL 14

Accepted Solution

by:
Giovanni Heward earned 500 total points
ID: 39754440
If that fails you may just want to copy the happybday.jpg into the backgrounds folder and keep it there the entire time, once the big day arrives your script can just rename the existing background (to be restored the next day) and rename the happybday.jpg to backgroundDefault.jpg

If you make any changes to the graphic, you can just push/pull them down to the machine.
0
 

Author Comment

by:FT-Techs
ID: 39754731
ok, we may use GPO to push out the registry change and files and i will do as you say and just modify it.  thanks for your help.
0
 

Author Closing Comment

by:FT-Techs
ID: 39754735
very helpful, i figured out why it wouldnt work. it was user error. i needed to make sure that both anonymous and everyone was set to read and execute on the share, the folder security, and the image. i was missing the everyone option on one of thoes. i could see the image but it wouldnt apply. but that fixed it.
anyone know how or if you can change the default location that the image is pulled from? i understand it goes to the oobe\info folder, is there a way to change it to a different folder?
0
 
LVL 14

Expert Comment

by:Giovanni Heward
ID: 40217940
Create a symbolic link (replacing oobe\info) that points to the alternate folder location.  Verify access permissions.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Many admins will agree: WSUS is is a nice invention but using it on the client side when updating a newly installed computer is still time consuming as you have to do several reboots and furthermore, the procedure of installing updates, rebooting an…
This is a little timesaver I have been using for setting up Microsoft Small Business Server (SBS) in the simplest possible way. It may not be appropriate for every customer. However, when you get a situation where the person who owns the server is i…
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

911 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now