This code will loop through integers 1 through 10, displaying each with a message box
Sub ForLoop() Dim i As Integer For i = 1 To 10 MsgBox i Next i End Sub