Given the listbox with a few lines.
How do I read the lines?
How do I complete the line below beginning with "str ="
The result should be the same string ad added using AddItem.
TIA
Best regards
Erik
Private Sub UserForm_Initialize() ListBox1.AddItem "1value" ListBox1.AddItem "2value" ListBox1.AddItem "3value" ListBox1.AddItem "4value" ListBox1.AddItem "5value" End Sub Private Function GetValue() As String Dim str As String Dim idx As Integer idx = 1 str = [*******...Code to Get one value...*******] ListBox1.RemoveItem (idx - 1) GetValue = str End Function