VB.NET take each letter of a word and display in ListBox
- by Kaleet
Private Sub btnWord_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnWord.Click
Dim Inputter As String
Dim Words As String = ""
Do
Inputter = InputBox("Enter word", "Enter Word")
If Inputter <> String.Empty Then
lstDisplay.Items.Add(Inputter)
Word += Inputter.Substring(0, 1)
End If
Loop Until Inputter <> String.Empty
' SOMETHING GOES HERE!!!!!'
lstDisplay.Items.Add("---")
lstDisplay.Items.Add(Word)
End Sub
Here is how it works, when you click the button it displays an input box so for example type in "CAT".
But I can't figure out how to get it to do C (newline) A (newline) T (newline) within the listbox. Please help!
C
A
T
-
CAT