by Chris Welty (1 Submission)
Category: Graphics
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Fri 21st May 1999
Date Added: Mon 8th February 2021
Rating: (1 Votes)
Brings up different sized bubbles and does other misc. things. Works great as a screansaver.
API Declarations
Public Declare Function GetDesktopWindow Lib "user32" () As Long
Public Declare Function SetWindowPos Lib "user32" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long
Public Const SWP_NOSIZE = &H1
Public Const SWP_NOMOVE = &H2
Public Const HWND_TOPMOST = -1
Public Const HWND_NOTOPMOST = -2
Public Const FLAGS As Long = SWP_NOMOVE Or SWP_NOSIZE
Private Sub Form_Click()
FillColor = RGB(Int(Rnd * 255), Int(Rnd * 255), Int(Rnd * 255))
FillStyle = 0
Circle (Int(Rnd * 11970), Int(Rnd * 8985)), Int(Rnd * 255)
DoEvents
End Sub
Private Sub Form_DblClick()
End
End Sub
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
Do
FillColor = RGB(Int(0), Int(0), Int(0))
FillStyle = 0
Circle (Int(Rnd * 11970), Int(Rnd * 8985)), Int(Rnd * 255)
DoEvents
Loop
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single)
Do
FillColor = RGB(Int(Rnd * 255), Int(Rnd * 255), Int(Rnd * 255))
FillStyle = 0
Circle (Int(Rnd * 11970), Int(Rnd * 8985)), Int(Rnd * 255)
DoEvents
Loop
End Sub
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, x As Single, y As Single)
Do While True
' SetWindowPos Form1.hwnd, HWND_TOPMOST, 0, 0, 0, 0, FLAGS
' SetPixel Form1.hdc, Int(Rnd * 800), Int(Rnd * 600), RGB(Int(Rnd * 255), Int(Rnd * 255), Int(Rnd * 255))
FillColor = RGB(Int(255), Int(255), Int(255))
FillStyle = 0
Circle (Int(Rnd * 11970), Int(Rnd * 8985)), Int(Rnd * 255)
DoEvents
Loop
End Sub
No comments have been posted about Brings up different sized bubbles and does other misc. things. Works great as a screansaver.. Why not be the first to post a comment about Brings up different sized bubbles and does other misc. things. Works great as a screansaver..