This code will help u to marquee a text within a label.
This code will help u to marquee a text within a label.
Rate This code will help u to marquee a text within a label.
(1(1 Vote))
Private Sub Form_Load()
Me.Timer1.Enabled = False
str = Label1.Caption
End Sub
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.Label1.BackColor = vbBlack
Me.Label1.ForeColor = &HFF8080
Timer1.Enabled = False
Me.Label1.Caption = Trim(str)
Label1.Alignment = 2
End Sub
Private Sub label1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.Label1.BackColor = &HFF8080
Me.Label1.ForeColor = vbBlack
Me.Timer1.Enabled = True
Label1.Caption = Trim(Label1.Caption)
Label1.Alignment = 2
End Sub
Private Sub Timer1_Timer()
Label1.Caption = Label1.Caption + " "
If Len(Me.Label1.Caption) >= 56 Then
Label1.Caption = Right(Label1.Caption, Len(Label1.Caption) - 1)
End If
If Left(Me.Label1.Caption, 1) = " " Then
Label1.Alignment = 1
Label1.Caption = str
End If
End Sub
'make sure all the controls are taken in the form.
'Please reply how you like our service
'Please reply to [email protected]
This code will help u to marquee a text within a label. Comments
No comments yet — be the first to post one!
Post a Comment