What is your result here?<br>Scroll Automatically?<br><br>Need more Input... <p>DougP<br><a href=mailto: dposton@universal1.com> dposton@universal1.com</a><br><a href= > </a><br> Ask me how Bar-codes can help you be more productive.
basically you want to create a marquis effect. the only way that i can think of doing this without trying to locate a predesigned utility to do such would be to have code behind it that had a timer involved that actively changed the visible text in the following manner:<br><b><br>Visible text in textbox.<br>isible text in textbox.<br>sible text in textbox. V<br>ible text in textbox. Vi<br></b><br>etc...<br><br>you would probably have to type out every possible variable here, and then have a loop with a timer that just changed it at a set interval that made it appear to move.<br><br>i'm not that good with loops, so i'm not sure if this would work or not. i'm curious to know if it does though. <p>Brian Famous<br><a href=mailto:bfamous@ncdoi.net>bfamous@ncdoi.net</a><br><a href= > </a><br>
just a quick thought on how to loop it <br>real rough code below <br><br>dim leftvar as integer, rightvar as integer<br>loop<br>leftvar=leftvar-1 ,rightvar = rightvar=1<br>left([text],leftvar) right([text],rightvar)<br>if variables = len([text]) reset variables<br>end if<br>return loop<br>better then typing every possible variable<br>
Working code for scrolling text<br>create an unbpund text box then place this code under the froms on timer event. be sure to replace where it says your stuff with your fields<br><br>Private Sub Form_Timer()<br>Dim textlen As Integer<br>Static astr As Integer<br>Dim textstr As String, a As Integer<br>textlen = Len(Me.[Your field name])<br>astr = astr + 1<br>If astr >= textlen Then astr = 1<br>textstr = Mid([Your field name], astr, Len([Your field name])) & " " & Left([Your field name], astr)<br>Me.Your unboundtextbox.Value = textstr<br><br>End Sub<br><br>need to place 1000 on forms timer interval<br>
glo4, I just implemented your code on one of my main forms and it works Super!!! Thanks alot for posting that very helpful tip.
As for lunchboxkid, if you are referring to Access's default switchboard you can still use this code as well, just like you would on any other form. Be sure to stick this code in the forms on timer() event and set the timer interval() as well.
Hi glo4!!!
i have not got this code correct.
assume that i want a label on a form label30 "Company Balance Sheet" form name opening page scrolling i understand most of the timer code and the duration.but what do i insert in field name and text7 at the bottom. i am missing something
regards
john
Bournemouth England
genesis2000ad@yahoo.co.uk
Just paste this code
'<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Private Sub Form_Timer()
Dim textlen As Integer, textstr As String
Dim strfield As Variant
Static astr As Integer
strfield = "Company Balance Sheet" &"" 'static data so Jut typed it in
textlen = Len(strfield)
astr = astr + 1
If astr >= textlen Then astr = 1
textstr = Mid([strfield], astr, Len([strfield])) & " " & Left([strfield], astr)
Me.label30.caption = textstr 'replaced with labelname.caption
end sub
'>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
set timer interval to around 500
It's all in the FAQ hope this clears it up for you
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.