Click here to Skip to main content
15,921,694 members
Articles / Web Development / ASP.NET

How to Fill a ListBox/DropDownList from an Enum

Rate me:
Please Sign up or sign in to vote.
4.13/5 (7 votes)
22 Aug 2009CPOL 49.8K   17  
There was a question about this on the ASP.NET forums and after a quick search I didn't find a good generic function so I thought I'd supply one. Note: I wanted this to be as broad and useful as possible, so the second parameter is a ListControl which both the ListBox and DropDownList inherit from.

Views

Daily Counts

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
EndWell Software, Inc.
United States United States
I am an independent contractor/consultant working in the Twin Cities area in Minnesota. I work in .Net, Asp.Net, C#, C++, XML, SQL, Windows Forms, HTML, CSS, etc., etc., etc.

Comments and Discussions