Is this what you need? Put a command button, a textbox and a listbox on a form....put your string in the textbox and click on the cmdbtn
Code:private sub Command1_click() Dim x As Integer, y As Integer, myText As String myText = Trim(Text1.Text) y = 0 For x = 1 To Len(myText) - 1 myText = Left(myText, 0 + (y)) & Mid(myText, y + 1, 1) & "," & Mid(myText, y + 2) List1.AddItem myText y = y + 2 Next x End Sub




Reply With Quote