AuthorMessage
C0D3Z3R0
Pro
Posts: 166

Hi, does anyone know how to use the split function properly in vb6 or have an example on how to use it? I can't find an example anywhere on how to use it, thanks
Meka][Meka
Unstopable
Posts: 700

sure here is a quick example for form load
Code:

'Quick Split example vb6 - ( Meka][Meka )
Private Sub Form_Load()
'var
    Dim s       As String
    Dim lol()   As String  ' array u will hold the strings
    Dim i       As Integer
'begin
    s = "lol$lol2$lol3" 'string that u will split :)
   
    lol = Split(s, "$", , vbTextCompare) ' split this biatch :-O!
    s = vbNullString 'clear s
   
    For i = 0 To UBound(lol) 'loop thru them
        MsgBox (lol(i)) 'show a message box with the value
    Next i 'go back to for
'end
End Sub

; M E K A ;