I am new student. Just trying to have user enter 10 values that display in listbox. What is wrong with inValue = InputBox("Enter a number.")
Code:
Private Sub btnInputValues_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnInputValues.Click
Dim inValue(9) As Integer
Dim I As Integer
I = 0
Try
inValue = InputBox("Enter a number.")
For I = 0 To 9
lstValues.Items.Add(inValue)
Next
Catch ex As Exception
MessageBox.Show("Please Enter a valid number.")
End Try