Rolling credits list

A

Archie

I would like to add a userform with a rolling credit list.
I ca only find static text items like 'Label', 'TextBox'' etc.
I need something that scrolls automaticly by, lets say, 2 lines per second.

Archie
 
G

Guest

Why not a "listbox." Use blank list item entries for intro and homespun
timer/counter to remove entries and rewrite. Jason
 
K

keepITcool

Adapt from following:

create a userform with 2 controls:
1 commandbutton
1 label (high enough for several lines.. e.g. 64points)


Option Explicit

Private Declare Sub Sleep Lib "kernel32.dll" ( _
ByVal dwMilliseconds As Long)

Const DELIM As String = ","
Dim bEsc As Boolean

Private Sub Shift(s As String)
Dim i&
i = InStr(1, s, DELIM)
s = Mid$(s, i + 1) & DELIM & Left$(s, i - 1)
End Sub

Private Sub CommandButton1_Click()
bEsc = True
End Sub

Private Sub UserForm_Activate()
Dim s$
bEsc = False
s = ",,,,,,Example,Of,A,Rolling,Credits,List,,,,"

On Error GoTo theEnd
Application.EnableCancelKey = xlErrorHandler
Do Until bEsc
Label1 = Replace(s, DELIM, vbLf)
Shift s
DoEvents
Sleep 400
Loop

theEnd:
End Sub

Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
bEsc = True
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top