Screensaver Problem. Help!

This is a discussion on Screensaver Problem. Help! within the Windows Programming forums, part of the Platform Specific Boards category; I've been learning SDL for the past few weeks, and I like it a lot. I made a program in ...

  1. #1
    Registered User
    Join Date
    Sep 2002
    Posts
    22

    Question Screensaver Problem. Help!

    I've been learning SDL for the past few weeks, and I like it a lot. I made a program in which you can shoot a spaceman around on Mars's surface. I then wondered if I could make it a screen saver. So the first thing I did was change it from mars.exe to mars.scr. When I double-clicked, it worked. So then I right-clicked the file and click "install" (in Windows 2000). Then I went to "test" and it worked fine. So I figured it was all good. But when I set it to 1 minute and waited for it to come it, I just got a black screen for a second and then the program ended.

    What am I missing?? Please help! Thanks in advance.

    -Joe

  2. #2
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,831
    Has your .exe been built as a screen saver or is it just an .exe? If so, there is more to a screen saver than that.

    A screensaver does not have a WinMain() rather it uses ScreenSaverProc(). It should also contain ScreenSaverConfigureDialog() and RegisterDialogClasses() although both of these routines can be simple placeholders.

    It is also necessary for all screensavers to have a special icon resource and a string for it's title, (24 characters max), used in the control panel.

    If you have not got any of these things, it will not work.

    There is more you can do, but these things you must do.

    Check out these routines at MSDN or the compiler help.
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need help understanding a problem
    By dnguyen1022 in forum C++ Programming
    Replies: 2
    Last Post: 04-29-2009, 04:21 PM
  2. Memory problem with Borland C 3.1
    By AZ1699 in forum C Programming
    Replies: 16
    Last Post: 11-16-2007, 10:22 AM
  3. Someone having same problem with Code Block?
    By ofayto in forum C++ Programming
    Replies: 1
    Last Post: 07-12-2007, 08:38 AM
  4. A question related to strcmp
    By meili100 in forum C++ Programming
    Replies: 6
    Last Post: 07-07-2007, 02:51 PM
  5. WS_POPUP, continuation of old problem
    By blurrymadness in forum Windows Programming
    Replies: 1
    Last Post: 04-20-2007, 06:54 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21