none
Installing a SCR file

    Question

  • I have questions about proper installation of a screen saver (SCR) file under Windows Vista.

    1. When using an installer, is the proper method to copy the SCR file to the C:\Windows folder and set the registry key?  Or is better to do something like in #2 below...

    2. If you right-click a SCR file, Vista has a popup menu which offers to "Install" the screensaver for you.   

    2a. Technically, how does this work exactly? 

    2b. Is there a way to get this function to work via the API?  In other words, can one create a SCR file which when activated on the desktop, calls the self-install methods?

     

     

    Thursday, February 01, 2007 9:05 PM

Answers

  • Screensavers can be placed in a number of locations.  Here is the list of searched directories in priority order (duplicate names will not be listed):

     

    - System folder (architecture specific)

    - Windows folder

    - Existing screensaver folder (which ever screen saver is currently set to run)

     

    All unique *.scr files in these directories will be enumerated in the screen saver dialog.  Note that this means if a user changes the current screensaver to one in the system or windows directories, future invocations of the screensaver dialog will not yield the custom directory. 

     

    You can set the screensaver during install in the registry to SCRNSAVE.EXE” in HKLM’s "Software\\Microsoft\\Windows NT\\CurrentVersion\\ScreenSavers"to the screensaver you want.

    Tuesday, February 06, 2007 9:54 PM
  • 1. The recommendation is to use an MSI to install it.

    2. The "Install" menu option acts as "set active screen saver".

     

     

    Tuesday, February 06, 2007 10:16 PM

All replies

  • I'm looking into this and will get back with you.
    Tuesday, February 06, 2007 2:21 AM
  • Screensavers can be placed in a number of locations.  Here is the list of searched directories in priority order (duplicate names will not be listed):

     

    - System folder (architecture specific)

    - Windows folder

    - Existing screensaver folder (which ever screen saver is currently set to run)

     

    All unique *.scr files in these directories will be enumerated in the screen saver dialog.  Note that this means if a user changes the current screensaver to one in the system or windows directories, future invocations of the screensaver dialog will not yield the custom directory. 

     

    You can set the screensaver during install in the registry to SCRNSAVE.EXE” in HKLM’s "Software\\Microsoft\\Windows NT\\CurrentVersion\\ScreenSavers"to the screensaver you want.

    Tuesday, February 06, 2007 9:54 PM
  • 1. The recommendation is to use an MSI to install it.

    2. The "Install" menu option acts as "set active screen saver".

     

     

    Tuesday, February 06, 2007 10:16 PM
  • Thanks for the info.   I think the question I have now is whether there is an "approved" folder location for installing a SCR file that's only for a single user.   For example, should it go inside the Documents folder?  Or perhaps inside AppData?    Seems like there ought to be a location for a non-admin user to put it...

    Sunday, February 11, 2007 9:10 AM
  • Hi,

    I would just like to know if you ever got any more info regarding this. I have an app that runs as a screensaver purely to use it's facility to "block" Ctrl+Alt+Delete. It is a security "PC locking" app and although I can trap keys to my heart's content, Windows does not allow one to block Ctrl+Alt+Delete. I therefore install my app as a screensaver and insist on "On resume, password protect" being ticked. This way I can completely "lock" the PC and limit a user to what my application allows him to do.

    Just wanted to clarify the above so that no-one thinks "whoo, screensaver developer... we'll get right on HIS problem... NOT!".

    I install the screensaver in code (C#.NET) by setting registry entries in HKEY_CURRENT_USER\Control Panel\Desktop: SCRNSAVE.EXE, ScreenSaveActive and ScreenSaverIsSecure.

    Where do I install the scr file? I cannot assume that the user has access to Windows\System32. When I simply set the current screensaver file in the registry (HKEY_CURRENT_USER\Control Panel\DesktopTongue TiedCRNSAVE.EXE) to the path of my scr file in some arbitrary folder, it seems to work, and the screensaver comes up the first few times, but then the setting seems to disappear by itself... I literally sat and watched my pc for 10 minutes, screensaver set on 1 minute: it comes up, I close it and wait... it comes up, I close it and wait... etc. Suddenly instead of the screensaver comming up only the Windows logon screen appears, as it would when one closes the screensaver with "On resume password protect" is ticked. When I go to the Desktop properties - Screensaver it has misteriously been set to "None". It seems like at some point Windows decides to "refresh" it's list of screensavers, obviously doesn't find mine as it's not in wondows\system32, and the promptly sets the screensaver to None.

    I am running Windows XP SP3, and I am not on a corporate network where any policies can have an effect. I have infact reinstaleld Windows less than a week ago, so no misterious setting mess-up could have occurred.

    My feeling is that there should be an alternative fo,lder to which one can install the scr files, other that system32. One that you can be certain the user has rights to. Can anyone suggest a solution? Am I missing something?

    Thanks in advance.
    Tuesday, April 15, 2008 9:02 PM
  • Maarten van de Bospoort MSFT said:

    Screensavers can be placed in a number of locations.  Here is the list of searched directories in priority order (duplicate names will not be listed):

     

    - System folder (architecture specific)

    - Windows folder

    - Existing screensaver folder (which ever screen saver is currently set to run)

     

    All unique *.scr files in these directories will be enumerated in the screen saver dialog.  Note that this means if a user changes the current screensaver to one in the system or windows directories, future invocations of the screensaver dialog will not yield the custom directory. 

     

    You can set the screensaver during install in the registry to SCRNSAVE.EXE” in HKLM’s "Software\\Microsoft\\Windows NT\\CurrentVersion\\ScreenSavers"to the screensaver you want.


    Bump to an old thread -- So, if I'm understanding this properly, this presents an issue for a non-administrator user:  they aren't allowed to write to the System or Windows folder, so the only way to install the screensaver would be to put it in their documents folder (etc.).   However, if they ever choose a different screensaver, then the next time they go to the screensavers dialog, the custom screensaver won't be listed any more since the search path no longer includes that folder.    Is this correct?

    Is the only solution to require elevated permissions to install a screensaver?

    Saturday, February 07, 2009 5:10 PM