Scrolling text in a text box
Heres your chance to share your own tutorials with the community. Just post them on here. If your lucky they may even be posted on the main site.
4 posts
Page 1 of 1
First add 1 timer and 1 textbox to form: enable timer 1 figure out your time you want
then right click form click view code and copy and paste this code.
Exampler:

then right click form click view code and copy and paste this code.
Code: Select all
Debug and done! Public Class Form1
Public Function MarqueeLeft(ByVal Text As String)
Dim Str1 As String = Text.Remove(0, 1)
Dim Str2 As String = Text(0)
Return Str1 & Str2
End Function
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
TextBox1.Text = MarqueeLeft(TextBox1.Text)
End Sub
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Timer1.Start()
End Sub
End Class

Exampler:

<a href="http://www.points2shop.com/s/xbox_point ... 5082"><img src="http://points2shop.com/images/promotion ... ricoxg.gif" border="0"/></a>
nice share mate 
this works with label too

this works with label too

Code: Select all
Public Class Form1
Public Function MarqueeLeft(ByVal Text As String)
Dim Str1 As String = Text.Remove(0, 1)
Dim Str2 As String = Text(0)
Return Str1 & Str2
End Function
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
Label1.Text = MarqueeLeft(Label1.Text)
End Sub
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Load
Timer1.Start()
End Sub
End Class
Find my programs on Softpedia
I know it can work with anything with text if done right #mshimranpro
<a href="http://www.points2shop.com/s/xbox_point ... 5082"><img src="http://points2shop.com/images/promotion ... ricoxg.gif" border="0"/></a>
4 posts
Page 1 of 1
Copyright Information
Copyright © Codenstuff.com 2020 - 2023