ticker tape like continuous display

  • Thread starter Thread starter Doug F.
  • Start date Start date
D

Doug F.

I want a scrolling, looping, continous band of data on display.
It's for the results of a silent auction as they come in. We would
project the scroll on overhead screens.
Thanks.
 
Doug said:
I want a scrolling, looping, continous band of data on display.
It's for the results of a silent auction as they come in. We would
project the scroll on overhead screens.


Try something like this code in the form's module:

Private pos As Long

Sub latestbidtextbox_AfterUpdate()
Me.allbidstaxtbox = Me.allbidstextbox _
& Me.latestbidtextbox
End Sub

Sub Form_Timer()
pos = pos + 1
Me.tickertextbox = Mid(Me.allbidstextbox, pos)
End sub

Try setting the form's TimerInterval property to 500 and
fine tune it to suit.
 
How you implement it depends on how you want it displayed. From what I can
tell, Marshall's suggestion will keep appending new bids to the end of a
string of all bids, and remove one character at a time from the front of the
string. This means the first item will disappear after some time, never to be
shown again, then the 2nd,etc. If that's what you want then that will work.
If you want something similar to what you see on TV, where the same thing
keeps scrolling by over and over, that requires some more logic. Do you want
all items to be displayed as you go along, with new ones added on as needed,
repeating over and over? If that's what you're looking for, then I think you
want the timer event something like:

if pos < len(allbidstextbox) then
pos = pos +1
if pos > 1 then
frontEnd = mid(allbidstextbox, pos-1)
else
frontEnd = vbNUllString
end if
else
pos = 1
frontEnd = vbNUllString
end if
tickertextbox = Mid(allbidstextbox, pos) & frontEnd

Then whenever a new item is added, add the new item to the end of the
textbox that holds the entire string like Marshall showed and reset pos to 0.
And the pos variable should start at 0 initially, when the form opens. I
think this will work similar to the way the repeating TV-type tickertapes
work.
 
Thanks, this gives me a good start point.

Marshall Barton said:
Try something like this code in the form's module:

Private pos As Long

Sub latestbidtextbox_AfterUpdate()
Me.allbidstaxtbox = Me.allbidstextbox _
& Me.latestbidtextbox
End Sub

Sub Form_Timer()
pos = pos + 1
Me.tickertextbox = Mid(Me.allbidstextbox, pos)
End sub

Try setting the form's TimerInterval property to 500 and
fine tune it to suit.
 
Thanks, Jim. Yes I want repeating.

Jim Burke in Novi said:
How you implement it depends on how you want it displayed. From what I can
tell, Marshall's suggestion will keep appending new bids to the end of a
string of all bids, and remove one character at a time from the front of the
string. This means the first item will disappear after some time, never to be
shown again, then the 2nd,etc. If that's what you want then that will work.
If you want something similar to what you see on TV, where the same thing
keeps scrolling by over and over, that requires some more logic. Do you want
all items to be displayed as you go along, with new ones added on as needed,
repeating over and over? If that's what you're looking for, then I think you
want the timer event something like:

if pos < len(allbidstextbox) then
pos = pos +1
if pos > 1 then
frontEnd = mid(allbidstextbox, pos-1)
else
frontEnd = vbNUllString
end if
else
pos = 1
frontEnd = vbNUllString
end if
tickertextbox = Mid(allbidstextbox, pos) & frontEnd

Then whenever a new item is added, add the new item to the end of the
textbox that holds the entire string like Marshall showed and reset pos to 0.
And the pos variable should start at 0 initially, when the form opens. I
think this will work similar to the way the repeating TV-type tickertapes
work.
 
Back
Top