Invoke Screen Saver

  • Thread starter Thread starter Thom Little
  • Start date Start date
T

Thom Little

How do I invoke the current screen saver with C#?

Where did you find the information on how to do it?
 
You can start any screen saver from the command line like this:
start C:\WINDOWS\system32\ssflwbox.scr /s

The current screen saver can be found in the registry:
HKEY_CURRENT_USER\Control Panel\Desktop

As for starting an exe in C#:
Process myProcess = Process.Start(ScreenSaverPath);

So if you combine all those in you code you should be able to
invoke the current screen saver.
 
Thank yo for the lead. It is now working and I am reading the values
out of the Registry to control it.

I would like to be able to specify ...

rkScreenSaver.SetValue( "ScreenSaveActive", "0" );

... to disable the screensaver but I am prevented from writing to the
Registry.

Do you have an idea on what I need to wrote to the Registry?

BTW ... your message was deleted from the major Microsoft newsgroup for
some reaswon.

... Thom
 
Hi Thom,

I found your further concern of change the registry value has been posted
in a new post in this group.

I have added a reply to you in that new post, please follow up there, I
will help you.

Thanks for your understanding.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top