Author : ojas
Date Submitted : 1/10/2005
Category : Custom Controls
Compatibility : VB 6
This code has been accessed 3227 times.
Task : This program will change background colour of the form as you scroll the scrollbars
Declarations
Code
Private Sub Form_Load()
Form1.WindowState = 2
End Sub
Private Sub Command1_Click()
Dim s As String
s = MsgBox("Are you sure?", vbYesNo)
If s = vbYes Then
End
End If
End Sub
Private Sub HScroll1_Change()
Form1.BackColor = RGB(HScroll1.Value, HScroll2.Value, HScroll3.Value)
End Sub
Private Sub HScroll1_Scroll()
Form1.BackColor = RGB(HScroll1.Value, HScroll2.Value, HScroll3.Value)
End Sub
Private Sub HScroll2_Change()
Form1.BackColor = RGB(HScroll1.Value, HScroll2.Value, HScroll3.Value)
End Sub
Private Sub HScroll2_Scroll()
Form1.BackColor = RGB(HScroll1.Value, HScroll2.Value, HScroll3.Value)
End Sub
Private Sub HScroll3_Change()
Form1.BackColor = RGB(HScroll1.Value, HScroll2.Value, HScroll3.Value)
End Sub
Private Sub HScroll3_Scroll()
Form1.BackColor = RGB(HScroll1.Value, HScroll2.Value, HScroll3.Value)
End Sub
Private Sub Timer1_Timer()
Timer2.Enabled = True
End Sub