Solved

How to display displaymember of Listbox using c#, .net winforms

Posted on 2009-05-05
2
519 Views
Last Modified: 2012-05-06
My listbox is binded as follows:
this.lstActiveClients.DisplayMember = "name";
this.lstActiveClients.ValueMember = "client_key";

on the SelectedIndexChanged,  i want to set client name textbox to the display member
private void lstActiveClients_SelectedIndexChanged(object sender, EventArgs e)
        {
            this.txtClientName.Text = ??
 
        }

Open in new window

0
Comment
Question by:michael1174
2 Comments
 
LVL 5

Accepted Solution

by:
Aanvik earned 125 total points
ID: 24305324
lstActiveClients.Text


0
 
LVL 2

Author Closing Comment

by:michael1174
ID: 31578040
thanks!
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Although it is an old technology, serial ports are still being used by many hardware manufacturers. If you develop applications in C#, Microsoft .NET framework has SerialPort class to communicate with the serial ports.  I needed to…
We all know that functional code is the leg that any good program stands on when it comes right down to it, however, if your program lacks a good user interface your product may not have the appeal needed to keep your customers happy. This issue can…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question