Daily Archives: October 9, 2015

1 post

[Solved] Cannot have multiple items selected in a DropDownList

If you work on ASP.NET DropDownList, most likely you will encounter a situation when you need to pre-select an item in the DropDownList. You might see people using the following way to do that after the DropDownList is bound: this.ddlSchools.SelectedValue = oSchool.AdminID This works very well if you are sure that the value you assign to the DropDownList actually is one of┬áthe DropDownList items, otherwise, you will get an ArgumentOutOfRangeException. So the safe way to […]