Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3353026
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T02:06:05+00:00 2026-05-18T02:06:05+00:00

From the examples below showing the loading of a DropDownList in ASP.NET which method

  • 0

From the examples below showing the loading of a DropDownList in ASP.NET which method is preferred and why?

Method 1:

Build an array of ListItem objects loaded with entity information and use the DropDownList.Items.AddRange method to load the list.

Method 2:

Build a BindableList<T> collection of entity objects and use the DropDownList.DataSource method to load the list.

Method 3:

Build a List<T> collection of entity objects and use the DropDownList.DataSource method to load the list.

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T02:06:06+00:00Added an answer on May 18, 2026 at 2:06 am

    All methods results same for dropdown but have their own pros and cons. Here are some short answers:

    Method 1 is tightly coupled with List Controls. I don’t prefer using method 1 because it don’t provide so much flexibility if in future i’ll have to bind to data to a grid it will not work.

    Speed: This method will be a bit slower if there are too many ListItems. Because you will have to Convert Business Entities to ListItem Object in order to fill dropdown.


    Method2 is good option if you choose to work with TwoWay databinding. But it is not supported in asp.net default controls and mechanism, so it will be used in vain with dropdown list.

    Speed: This method will be little faster because BindableList implements IEnumerable and it will be iterated once when DataBind is called.


    Method 3 is preferably good option because it is generic and extensible and can also work with any bindable object in .net.

    Speed: This method will be same as Method2 because List also implements IEnumerable and it will be iterated once when DataBind is called.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Solution: I've misinterpreted the example from SQL Books Online. Yes, that below the section
I have seen examples of printing from a windows application but I have not
From the help for the Overflow Error in VBA, there's the following examples: Dim
This is from an example accompanying the agsXMPP .Net assembly. I've read up on
This example is from php.net: <?php function Test() { static $a = 0; echo
As you can see from the example below, I have a black background and
How can I get only unique departments from the below example? Dept Id Created
I haven't used repeaters for much more than showing data from a datatable. I
I try to use a PageableListView with PagingNavigation. From the examples that looks quite
For example: from datetime import <c-x><c-o>{list of modules inside datetime package}

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.