Make Sure you already bind a Dropdown control..
for (int i = 0; i < ddlCountry.Items.Count; i++)
{
if (ddlCountry.Items[i].Text.ToString() == dsCustomer.Tables[0].Rows[0]["CountryName"].ToString().Trim())
{
ddlCountry.Items.FindByText(dsCustomer.Tables[0].Rows[0]["CountryName"].ToString().Trim()).Selected = true;
}
}
Ad
Search This Blog
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment