hey guys, me again. attempt number 2 on trying to get to the bottom of these arrays. i'm trying to display the highest number in an array and i am using the following code. can anyone tell me why it keeps giving me a result of zero. i have been searching through the forum and this was basically what i came out with.

(I can fill the array as i have a button that displays the numbers inputted into the array)

VB Code:
  1. Private Sub cmdHighest_Click()
  2. Dim Highest As Integer
  3. Dim Numbers(1 To 5) As Integer
  4.  
  5.  
  6. For Index = 1 To UBound(Numbers)
  7.        If Numbers(Index) > Highest Then
  8.        Highest = Numbers(Index)
  9.     End If
  10. Next Index
  11.  
  12.  
  13. lblHighest.Caption = Highest
  14.  
  15.  
  16. End Sub