sythez.orgz 0 Newbie Poster

Hello, can you help me guys with this little problem..

So i have a listbox, and whenever a new data comes in, its already the selected item. Then i need to compare that data if i have that already in my textboxes, else it will be put into textbox that has no data in it.

Here is my code so far..

    For x = 0 To listBox3.Items.Count
        a = listBox3.SelectedItem
        TextBox6.Text = a

        If listBox3.SelectedItem <> a Then
            b = listBox3.SelectedItem
            TextBox7.Text = b

        ElseIf listBox3.SelectedItem <> a & b Then
            c = listBox3.SelectedItem
            TextBox8.Text = c
        End If
    Next
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.