從下面的示例顯示在ASP.NET中加載DropDownList哪個方法是首選的,爲什麼?加載ASP.NET DropDownList對象
方法1:
構建載有實體的信息ListItem
對象的數組,並使用DropDownList.Items.AddRange
方法加載列表。
方法2:
構建BindableList<T>
集合實體對象,並使用DropDownList.DataSource
方法加載列表。
方法3:
構建List<T>
集合實體對象,並使用DropDownList.DataSource
方法加載列表。
在此先感謝。
類似(但不重複)這裏的問題:http://stackoverflow.com/questions/2243950/listt-vs-bindinglistt-advantages-disadvantages – RPM1984 2010-11-09 00:24:43