Private Sub btnGen_Click(ByVal sender As System.Object, ByVal e As _
             System.EventArgs) Handles btnGen.Click
  Dim i As Integer

  ReDim Numbers(Elements)     ' Określamy wielkość tablicy
  txtNumList.Text = ""        ' Czyścimy pole tekstowe do wyświetlania
                              ' wyniku

  For i = 0 To Elements
    Numbers(i) = CInt(Rnd() * 100)
    txtNumList.Text &= CStr(Numbers(i)) & vbCrLf
  Next i

End Sub
