Dim t As Integer Dim s(100) Private Sub Command1_Click() s1 = Text1.Text t = t + 1 For i = 0 To t - 1 If s1 >= s(i) Then For j = t - 1 To i Step -1 s(j + 1) = s(j) Next j s(i) = s1 Exit For End If Next i Label1.Caption = "" Label1.Caption = s(0) For i = 1 To t Label1.Caption = Label1.Caption + Chr(10) + s(i) Next i End Sub Private Sub Form_Load() t = 0 End Sub