Is this possible?

colinmunnelly

Registered User.
Local time
Today, 10:17
Joined
Feb 26, 2002
Messages
89
I have a label on a form that becomes visible when a check box is ticked. Is it possible to have the label or a text box flash on and off so it becomes an on screen warning. Answer is probably no but hey thought i would ask you clever people.
 
You can set the form's TimerInterval property to something appropriate (500 milliseconds seems to work nicely), and then use the OnTimer procedure to make the text box flash. The flashing may be accomplished by changing the text box or label's ForeColor and/or SpecialEffect property. You'll need to make the changes conditional on the check box being selected, and you may wish to limit the flashing to a particular length of time. Also, be aware that using the TimerInterval and OnTimer properties tends to produce quirky behavior when you're debugging the form.
 
Thanks for the reply but bit over my head. The ontimer procedure i assume this is done in code. If so can you give ma an example of it so i can play and adapt it.

C
 
Go to the Form properties and scroll to the bottom of the form events. As AlanS stated, 500 works really well for the timer interval. In the on Timer event, place the following:

If Check = -1 Then
If LBL.Visible = True Then
LBL.Visible = False
Else
LBL.Visible = True
End If
End If
 
slight improvement:

If Check = -1 Then
LBL.Visible = Not(LBL.Visible)
End If
 

Users who are viewing this thread

Back
Top Bottom