Hi,
On one of my sharepoint page, I want to populate dropdown list with countries, namely
<asp:DropDownList ID="ddlCountry" runat ="server"></asp:DropDownList>
In the code, I use LINQ:
var country = (from p in dc.ProvCountries
select p.country_code ).Distinct();
ddlCountry.DataBind();
I want the country_code to be the ID, while the country_name will be the display name in the dropdown, how can that be done?
Thanks in advance.