0% found this document useful (0 votes)
7 views1 page

"Muhammad Zulkarnaen" "Selamat Datang Di Lombok": Form1

This document defines a Windows Form application that uses a timer to slowly display a rolling message across a label. It initializes an array containing one greeting message, sets the form title, and enables a timer on load. The timer event handler increments a counter each tick and displays a substring of the message text based on the counter length, resetting the message and counter when the full text is displayed.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views1 page

"Muhammad Zulkarnaen" "Selamat Datang Di Lombok": Form1

This document defines a Windows Form application that uses a timer to slowly display a rolling message across a label. It initializes an array containing one greeting message, sets the form title, and enables a timer on load. The timer event handler increments a counter each tick and displays a substring of the message text based on the counter length, resetting the message and counter when the full text is displayed.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

Public Class Form1

Dim tulisan(0) As String


Dim i, j As Integer
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Me.Text = "Muhammad Zulkarnaen"
Timer1.Enabled = True
tulisan(0) = "Selamat datang di Lombok"
Label1.Text = tulisan(j)
End Sub
Private Sub Timer1_Tick(sender As Object, e As EventArgs) Handles Timer1.Tick
If i.Equals(tulisan(j).Length) Then
Me.Label1.Text = ""
If j < tulisan.Length - 1 Then
j=j+1
Me.Label1.Text = tulisan(j)
Else
j=0
End If
i=0
End If
Label1.Text = tulisan(j).Substring(0, i)
i=i+1
End Sub

Private Sub Label1_Click(sender As Object, e As EventArgs) Handles Label1.Click


End Sub
End Class

You might also like