Web Site Devloped By Abhishek Mishra
Tech. Help By Anand Mishra
Contact no. 9425355631

Powerd by Shree Guru Kripa Computer


vb.net_for_loop Program


This is vb.net_for_loop Program.Which is used for loop input number in "input box" and show number in "list box" . Add all of number show in a label and Average in a another label.

Public Class Form1
Dim A(5), I, S, AV As Int16
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
For I = 0 To 5
A(I) = InputBox("ENTER NUMBER")
Next
End Sub

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
For I = 0 To 5
ListBox1.Items.Add(A(I))
Next
Label1.Text = 5
Label2.Text = 5 / 6
End Sub
End Class