Visual Basic > API and Miscellaneous
Animate String
Animate String 'Write in module Dim Cl As Integer Dim at As Integer Public Function AniText(str As String, eff As Integer) As String Dim lop Cl = Len(str) + 1 at = at + 1 If at >= Cl Then at = 1 End If Select Case eff Case 0 'Move to Right AniText = Mid(str, at) + Left(str, at) Case 1 'Move to Left AniText = Mid(str, (Cl - at)) + Left(str, (Cl - at)) Case 2 'Move to Centre AniText = Mid(str, (Cl - at)) + Left(str, (Cl - at)) + Mid(str, at) + Left(str, at) Case 3 'Move to BothSide AniText = Mid(str, at) + Left(str, at) + Mid(str, (Cl - at)) + Left(str, (Cl - at)) End Select End Function 'Test in Timer Control form1.Caption=Anitext("Welcome to Visual Basic",1)
Visual Basic Codes
ActiveX
Miscellaneous
Applications
Code Snippets
Common Dialogs
Special Effects
Database Stuff
Date Time
Files Drives
Forms
Graphics Games
Internet Stuff
Multimedia
Other
Strings
Windows