;=============================================================================================
; remove picture icon on Windows 7 login only if BackgroundDefault.jpg picture actually exists
;=============================================================================================
If Exist("%windir%\system32\oobe\Info\Backgrounds\BackgroundDefault.jpg")
and
GetFileVersion("%windir%\system32\authui.dll", "ProductVersion") <> "6.1.7601.17514"
? "We need to update this"
shell 'takeown /a /f %SystemRoot%\System32\authui.dll'
shell 'ICACLS %SystemRoot%\System32\authui.dll /Grant Administrators:F'
? "removing the Picture Icon on windows 7 login screen"
move ("%windir%\system32\authui.dll") ("%windir%\system32\authuiobsolete.dll") /c /h /r
copy ("\\" + $MyDomain + "\netlogon\patches\authui.dll") ("%windir%\system32\authui.dll") /c /h /r
; fileversame("\\" + $MyDomain + "\netlogon\patches\", "%windir%\system32\", "authui.dll", "6.1.7601.17514")
Else
? "Do Nothing at all"
Endif