Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > .NET 2.0 and Visual Studio. 2005 > .NET Framework 2.0
.NET Framework 2.0 For discussion of the Microsoft .NET Framework 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the .NET Framework 2.0 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old December 27th, 2007, 12:41 AM
Registered User
Join Date: Nov 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to shehryar
Default Combo with multiple Display fields in ASP.Net

How can a combo box be used having multiple display fields when Dataset is used as its data source?

Shehryar Tariq
Old January 8th, 2008, 06:46 AM
samjudson's Avatar
Friend of Wrox
Join Date: Aug 2007
Posts: 2,128
Thanks: 1
Thanked 189 Times in 188 Posts

You can't as far as I am aware. You can add a calculated column to a datatable which could then be used perhaps?

/- Sam Judson : Wrox Technical Editor -/
Old January 8th, 2008, 02:13 PM
planoie's Avatar
Friend of Wrox
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts

Sam is correct. An ASP.NET DropDownList (there is not native combo box) is emitted and rendered as a standard HTML <select> element. This only allow a single string for it's value and display text. There are numerous 3rd party controls that provide combo box-like behavior for web apps however. You can also use the "poor-mans" approach and set your DDL to use a fixed width font and space delimit mutiple values so they appear tabular.


Similar Threads
Thread Thread Starter Forum Replies Last Post
Combo box to display items from parent combo box Gini Visual Studio 2008 0 June 18th, 2008 12:30 AM
Tooltip text setting for a combo in ASP.Net is req shehryar .NET Framework 2.0 1 January 8th, 2008 06:45 AM
To fetch selected fields in reports in asp.net 1.1 SanNil ASP.NET 1.0 and 1.1 Professional 0 February 27th, 2007 04:29 AM
Updating multiple Rows from multiple fields in ASP vdm_nana SQL Server ASP 0 April 1st, 2004 04:26 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.