Private Sub Command1_Click()
Dim i, tot, ss As Integer, zf, hs, arr() As String
tot = Len(Text1.Text)
For i = 1 To tot
zf = Mid(Text1, i, 1)
If zf = " " Or zf = "," Then
hs = Mid(Text1, i + 1, 1)
If (Asc(hs) > 65) And (Asc(hs) < 90) Then
arr(i + 1) = arr(i + 1)
End If
ss = Asc(hs) - 32
arr(i + 1) = Chr(ss)
End If
Next i
For i = 1 To tot
Print arr(i)
Next i
End Sub
为什么我的程序会越界呢?arr(i + 1) = Chr(ss)哪里越界了?