From the posts thus far, am I right in understanding that
is a STRING array, and
VB Code:
strArr = Split(arg1, arg2)
is a VARIANT populated with strings and that there is a difference between the two?
If so
VB Code:
Private Sub Command1_Click()
Dim strT As String
Dim varT As Variant
Dim strX() As String
Dim varX As Variant
strT = "A-TEST-FOR-FINDING-OUT-WHAT-SPLIT-DOES"
varT = "A-TEST-FOR-FINDING-OUT-WHAT-SPLIT-DOES"
MsgBox TypeName(strT)
MsgBox TypeName(varT)
strT = varT
MsgBox TypeName(strT)
strT = "A-TEST-FOR-FINDING-OUT-WHAT-SPLIT-DOES"
varT = strT
MsgBox TypeName(varT)
strX = Split(strT, "-")
varX = Split(varT, "-")
MsgBox TypeName(strX)
MsgBox TypeName(varX)
strX = varX
MsgBox TypeName(strX)
strX = Split(strT, "-")
varX = strX
MsgBox TypeName(varX)
ReDim strX(12) As String
strX(0) = "W"
strX(1) = "H"
strX(2) = "A"
strX(3) = "T"
strX(4) = " "
strX(5) = "I"
strX(6) = "S"
strX(7) = " "
strX(8) = "T"
strX(9) = "H"
strX(10) = "I"
strX(11) = "S"
strX(12) = "?"
MsgBox TypeName(strX)
strX = varX
MsgBox TypeName(varX)
End Sub
does not show any other result other than STRING() and/or STRING for the variables. Using VarType gives the undifferentiable result of 8200 for both as well, though I am not able to deciphet that result.