Is there a way to have a multiple field combo box using Microsoft Visual Studio with C#
MJV
0
Junior Poster in Training
Recommended Answers
Jump to PostYes, and it's very easy too.
Say we have table Student (ID#, FirstName, LastName)SqlDataSource.SelectCommand = "SELECT FirstName + ' ' + LastName AS FullName, ID FROM Student"; ComboBox.DataSource = SqlDataSource; ComboBox.SelectedText = "FullName"; ComboBox.SelectedValue = "ID"; ComboBox.DataBind();
Jump to PostMJV,
Ramy has provided the excepted and standard way to do this.
If you are looking for something a little more extreme, then check out :
http://www.codeproject.com/KB/combobox/multicolumncombo.aspxYou may also want to …
All 5 Replies
Ramy Mahrous
401
Postaholic
Featured Poster
JerryShaw
46
Posting Pro in Training
Ramy Mahrous
401
Postaholic
Featured Poster
JerryShaw
46
Posting Pro in Training
Ramy Mahrous
401
Postaholic
Featured Poster
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.