1,2,3,4,分别出值问题
比如a=1,2,3,4,5,6,7,8,9,10
有没有办法让
s1=1
s2=2
...
s10=10
将,号之间的字符串传递给不同变量
[解决办法]
arr=split(a, ", ")
s1=arr(0)
s2-arr(1)
...
[解决办法]
Private Sub Command1_Click()
Dim str As String
Dim strA() As String
Dim i As Integer
str = "1,2,3,4,5,6,7,8,9,10 "
strA = Split(str, ", ")
For i = 0 To UBound(strA)
Debug.Print strA(i)
Next
End Sub