I assume that this is a mouseclick event. What I want is that when I click a row in a listview, the first column that is an ID will automatically bind to a textbox.

I guess you could do it with Listview "Click"-event

public void MyListviewClickEvent( object sender, EventArgs e )
{
    ListView MyList = (ListView)sender;
    MyTextBox.Text = MyList.FocusedItem.SubItems[0].Text;
}
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.