Screen Saver

I am a beginner at VB and I am trying to make a very simple screen saver in VB 5.0.  I can make a form and save it as an .Scr OK, but when I go to the ‘Display’ menu in the Control Panel and click on ‘Preview’ it opens up too many forms and it does not display it in the little monitor screen provided.  

Many people have given me files containing code but they are no help to me at all because there is so much other rubbish with it I am unsure what I am doing.  Can anyone please give me the code on screen to sort this problem out.

I have not included a sub main with a .bas file which could be where I am going wrong?  Here is what I have so far….

Form Properties

Caption = ""
Start Up Position = 2 Maximum
Clip Controls = false
Show in Taskbar = false


Private Sub Form_MouseMove(Button As Integer, Shift As Integer, _
         X As Single, Y As Single)
         Static count As Integer
         If count > 2 Then
            count = count + 1
     End If
End Sub

Who is Participating?
mcriderConnect With a Mentor Commented:
First, read the following microsoft Article:

HOWTO: Create a Screen Saver in Visual Basic 

It says VB4, but the principles are the same.

Your program will have to handle command line options for 4 options:

   /S : Run normally, or in demo mode.

   /C : Open Configuration window.
   /A : Change the password.
   /P : Run in the Preview Window

You're really interrested in the /P option.  There is a full example of a screensaver at: 

Hope this helps!


Go to file menu, then select like if you where copiling it as .exe but in the name put the name but with .Scr like this


Then copile...

When the file is ready move it to the windows\system menu so that it appear with the others screensaver
SirNickAuthor Commented:
I am sorry that I have rejected your answer but I already know how to save it as a .SCR.  

The problem I have got is that once I have installed the screen saver I cannot get it to play in the monitor window provided in 'Display' option in the Control Panel when the 'Preview' button is pressed.

Thanks Anyway
SirNickAuthor Commented:
I am sorry that I have taken so long to answer.  
The information I got from the links you included in your answer were fine although it did take me a while to pick the code out I need.  

Many Thanks
Thanks for the points! Glad I could help!

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.