hi,can anyone help me with a code that can change form color after 10 seconds ,for example from yellow to red continiously.please help.
U can use Timer for this. Timer has interval property, which Specifies the number of milliseconds between calls to a Timer control's Timer event and Form.Backcolor property used to change the form color
Draw a Timer control and set its interval to 10000 (10 secs)
Use Form1.BackColor = vbRed This just change the BackColor to Red
Declare a boolean variable "flag" in Form Level (Top of the form) dim flag as boolean In the Timer1_Timer event Try the following
check flag variable , if it is false,
then Form1.BackColor = vbRed and make flag to true
else Form1.BackColor = vbYellow and make flag to false