Reputation: 1239
my dropdownlist HTML5
<select runat="server" id="ddlStateLegalRes" name="ddlStateLegalRes"></select>
On my page load I am binding my dropdownlist to a list collection with a list of states
Original question was answered created a new question as it is a different erorr
Upvotes: 2
Views: 90
Reputation: 33305
If I understand the question correctly you need to do this:
ddlStateLegalRes.Items.FindByValue(sdr["STATEOFLEGALRESIDENCE"].ToString()).Selected = true;
Upvotes: 1