none
Command line to reset theme back to Windows 7 default theme

    Question

  • I want to reset the themes of all my Windows 7 PCs via a logon script or batch file on a daily basis to the default Win7 aero one, since people have changed them to whatever they want.  Does anyone know of a command line command that will do that?
    Wednesday, November 14, 2012 2:20 PM

Answers

  • Here are the GP instructiosn for setting a them in Windows 7 GP.

    http://technet.microsoft.com/en-us/library/ee617164(WS.10).aspx

    Paay attention to: Load a specific theme

    If aa user has already logged in the just remove there profile and have them log into that computer again.  I would first move all of the personal folders using the redirector.  This should have been done for reliability and backup purposes anyway.  Doing this makes it easy to fix corrupt profiles by just deleteing the local copy.

     There is no reliable way to script the reset of a theme since it is jnot a setting but is a process that makes significant alterations to the registry/profile.

    You can also try to do it this way: http://windows7themes.net/windows-7-theme-group-policy.html


    ¯\_(ツ)_/¯

    Wednesday, November 14, 2012 4:20 PM

All replies

  • Thanks.  So if I'm reading this right, I just need to put this line into a batch file?  I've only ever dealt with batch files, or vbscripts (which I dont know how to create on my own, but i can understand them kinda reading through them).

    'rundll32.exe Shell32.dll,Control_RunDLL desk.cpl desk,@Themes /Action:OpenTheme /File:":"%windir%\\resources\\themes\\%YOUR_THEME_NAME%.theme"'

    Wednesday, November 14, 2012 2:59 PM
  • No, that only opens the control panel's Themes commandlet, which then requires the user to press the OK button to accept the selection.  As I read it, the solution suggests using the WScript.Shell's Sendkeys to 'press' the Enter key.  This is a rotten idea, prone to any number of problems.  Unfortunately, I don't have a solution for you, but I know this one is not it.  I suspect there is a group policy approach that can do the job instead, but I have no expertise in that area.

    Tom Lavedas

    Wednesday, November 14, 2012 3:19 PM
  • Use Group Policy to lock the desktop and prevent users from changing the theme.


    ¯\_(ツ)_/¯

    Wednesday, November 14, 2012 3:59 PM
  • That's what I'm planning on doing, once I get them all reset to something standard.
    Wednesday, November 14, 2012 4:01 PM
  • That's what I'm planning on doing, once I get them all reset to something standard.

    I believe you can also set the theme from GP.  Later I will check but that is usually part of a desktop GP.  I have used it to set a standard corporate custom theme in the past.


    ¯\_(ツ)_/¯

    Wednesday, November 14, 2012 4:05 PM
  • Thanks for helping.  I know with XP we used a script to change the desktop image via a GPO, but I want to change the theme so it also changes the screen you see at the logon prompt and everything else.
    Wednesday, November 14, 2012 4:07 PM
  • Thanks for helping.  I know with XP we used a script to change the desktop image via a GPO, but I want to change the theme so it also changes the screen you see at the logon prompt and everything else.

    Yes - that is what I am saying.

    ¯\_(ツ)_/¯

    Wednesday, November 14, 2012 4:11 PM
  • Here are the GP instructiosn for setting a them in Windows 7 GP.

    http://technet.microsoft.com/en-us/library/ee617164(WS.10).aspx

    Paay attention to: Load a specific theme

    If aa user has already logged in the just remove there profile and have them log into that computer again.  I would first move all of the personal folders using the redirector.  This should have been done for reliability and backup purposes anyway.  Doing this makes it easy to fix corrupt profiles by just deleteing the local copy.

     There is no reliable way to script the reset of a theme since it is jnot a setting but is a process that makes significant alterations to the registry/profile.

    You can also try to do it this way: http://windows7themes.net/windows-7-theme-group-policy.html


    ¯\_(ツ)_/¯

    Wednesday, November 14, 2012 4:20 PM