6

Possible Duplicate:
Where can I get a list of all countries/cities to populate a listbox?

Working on a system that needs a list of all countries, I've found that the common "trick" (*) of using CultureInfo and RegionInfo gives a list that is incomplete (missing Cuba, for example).

(*) See Country List for ComboBox or DropDown from .NET Globalization Namespace for one example.

Given that this approach fails, what's a better way to do this?

I guess we can fall back on adding a database table and manually populating a list of countries, but surely there's a smarter way.

Community
  • 1
  • 1
Bevan
  • 43,618
  • 10
  • 81
  • 133
  • could you perhaps create a list and if it's not in the list add to it.. for example I will paste a copy of a list below can you serialize the list if necessary – MethodMan Jan 04 '12 at 21:04
  • Why not just add them to you database manually? It's not like the list changes a lot – Oskar Kjellin Jan 04 '12 at 21:06
  • How dynamic and/or easily updatable does the list need to be? Whole new countries don't spring up all the time, but off the top of my head I can think of a new one that was created in 2011. – dgvid Jan 04 '12 at 21:10
  • 1
    @OskarKjellin It's the slowly changing nature that has me worried. Setting up the business process to keep something up to date daily is easy, and something that never changes needs no system. But something that changes slowly can be a problem because failure to keep it up to date isn't readily visible. – Bevan Jan 04 '12 at 22:26
  • @Bevan Then why do you need them 100%? – Oskar Kjellin Jan 05 '12 at 13:48

3 Answers3

9

There are also web services that provide this type of data, so perhaps you could periodically make use of a web service call and store it to local data store (e.g. a database or XML).

Reddog
  • 15,219
  • 3
  • 51
  • 63
  • 4
    Or - http://www.geonames.org/countries/ – Reddog Jan 04 '12 at 21:15
  • +1 to RedDog.. also if non of these answers work for you you could also consume a webservice to return a List then from there populate your dropdown so may possibilites.. – MethodMan Jan 04 '12 at 21:17
6

Which are the countries you're looking for? An what names do you want?

This is a list of all 193 members of the United Nations with their official designation (preceded by ISO 3166 code)

AD  Andorra
AE  United Arab Emirates
AF  Afghanistan
AG  Antigua and Barbuda
AL  Albania
AM  Armenia
AO  Angola
AR  Argentina
AT  Austria
AU  Australia
AZ  Azerbaijan
BA  Bosnia and Herzegovina
BB  Barbados
BD  Bangladesh
BE  Belgium
BF  Burkina Faso
BG  Bulgaria
BH  Bahrain
BI  Burundi
BJ  Benin
BN  Brunei Darussalam
BO  Bolivia (Plurinational State of)
BR  Brazil
BS  Bahamas
BT  Bhutan
BW  Botswana
BY  Belarus
BZ  Belize
CA  Canada
CD  Democratic Republic of the Congo
CF  Central African Republic
CG  Congo
CH  Switzerland
CI  Côte d'Ivoire
CL  Chile
CM  Cameroon
CN  China
CO  Colombia
CR  Costa Rica
CU  Cuba
CV  Cape Verde
CY  Cyprus
CZ  Czech Republic
DE  Germany
DJ  Djibouti
DK  Denmark
DM  Dominica
DO  Dominican Republic
DZ  Algeria
EC  Ecuador
EE  Estonia
EG  Egypt
ER  Eritrea
ES  Spain
ET  Ethiopia
FI  Finland
FJ  Fiji
FM  Micronesia (Federated States of)
FR  France
GA  Gabon
GB  United Kingdom of Great Britain and Northern Ireland
GD  Grenada
GE  Georgia
GH  Ghana
GM  Gambia
GN  Guinea
GQ  Equatorial Guinea
GR  Greece
GT  Guatemala
GW  Guinea-Bissau
GY  Guyana
HN  Honduras
HR  Croatia
HT  Haiti
HU  Hungary
ID  Indonesia
IE  Ireland
IL  Israel
IN  India
IQ  Iraq
IR  Iran (Islamic Republic of)
IS  Iceland
IT  Italy
JM  Jamaica
JO  Jordan
JP  Japan
KE  Kenya
KG  Kyrgyzstan
KH  Cambodia
KI  Kiribati
KM  Comoros
KN  Saint Kitts and Nevis
KP  Democratic People's Republic of Korea
KR  Republic of Korea
KW  Kuwait
KZ  Kazakhstan
LA  Lao People's Democratic Republic
LB  Lebanon
LC  Saint Lucia
LI  Liechtenstein
LK  Sri Lanka
LR  Liberia
LS  Lesotho
LT  Lithuania
LU  Luxembourg
LV  Latvia
LY  Libyan Arab Jamahiriya
MA  Morocco
MC  Monaco
MD  Republic of Moldova
ME  Montenegro
MG  Madagascar
MH  Marshall Islands
MK  The former Yugoslav Republic of Macedonia
ML  Mali
MM  Myanmar
MN  Mongolia
MR  Mauritania
MT  Malta
MU  Mauritius
MV  Maldives
MW  Malawi
MX  Mexico
MY  Malaysia
MZ  Mozambique
NA  Namibia
NE  Niger
NG  Nigeria
NI  Nicaragua
NL  Netherlands
NO  Norway
NP  Nepal
NR  Nauru
NZ  New Zealand
OM  Oman
PA  Panama
PE  Peru
PG  Papua New Guinea
PH  Philippines
PK  Pakistan
PL  Poland
PT  Portugal
PW  Palau
PY  Paraguay
QA  Qatar
RO  Romania
RS  Serbia
RU  Russian Federation
RW  Rwanda
SA  Saudi Arabia
SB  Solomon Islands
SC  Seychelles
SD  Sudan
SE  Sweden
SG  Singapore
SI  Slovenia
SK  Slovakia
SL  Sierra Leone
SM  San Marino
SN  Senegal
SO  Somalia
SR  Suriname
SS  South Sudan
ST  Sao Tome and Principe
SV  El Salvador
SY  Syrian Arab Republic
SZ  Swaziland
TD  Chad
TG  Togo
TH  Thailand
TJ  Tajikistan
TL  Timor-Leste
TM  Turkmenistan
TN  Tunisia
TO  Tonga
TR  Turkey
TT  Trinidad and Tobago
TV  Tuvalu
TZ  United Republic of Tanzania
UA  Ukraine
UG  Uganda
US  United States of America
UY  Uruguay
UZ  Uzbekistan
VC  Saint Vincent and the Grenadines
VE  Venezuela (Bolivarian Republic of)
VN  Viet Nam
VU  Vanuatu
WS  Samoa
YE  Yemen
ZA  South Africa
ZM  Zambia
ZW  Zimbabwe
frumbaela
  • 391
  • 1
  • 8
  • 4
    -1 The question isn't "where can I find a list of countries?" The question is, "what's a good solution for maintaining a list of countries as they change?" For that matter, how about a source for this data? – Dan J Jan 04 '12 at 23:41
  • 1
    @djacobson Then please tell me what a "good solution" should look like? The source is "doing it yourself"! Shall I upload it somewhere and replace my post with a link to that? Seems thats what's wanted here .. just a website that hosts a list which is created the same way I did mine. – frumbaela Jan 05 '12 at 02:11
  • 3
    See the answer with the most up votes for an example of a solution that addresses the concerns raised in the question, and note the OP's comment that "it's the slowly-changing nature that has me worried"; he's seeking a solution that doesn't require maintenance on his or his users' part. – Dan J Jan 05 '12 at 05:48
  • @djacobson You'd think people are still reading newspapers and such old things nowadays and would get it if there is a new member in the UN every 5 years, but whatever ... – frumbaela Jan 05 '12 at 13:49
  • 1
    Code to convert those values to Dictionary : http://pastebin.com/sWsBbZTe – Nigrimmist Nov 22 '16 at 16:02
2
<asp:DropDownList id="ddlCountry" runat="server">
<asp:ListItem Value="" Selected="True">Select Country</asp:ListItem>
<asp:ListItem Value="AF">Afghanistan</asp:ListItem>
<asp:ListItem Value="AL">Albania</asp:ListItem>
<asp:ListItem Value="DZ">Algeria</asp:ListItem>
<asp:ListItem Value="AS">American Samoa</asp:ListItem>
<asp:ListItem Value="AD">Andorra</asp:ListItem>
<asp:ListItem Value="AO">Angola</asp:ListItem>
<asp:ListItem Value="AI">Anguilla</asp:ListItem>
<asp:ListItem Value="AQ">Antarctica</asp:ListItem>
<asp:ListItem Value="AG">Antigua And Barbuda</asp:ListItem>
<asp:ListItem Value="AR">Argentina</asp:ListItem>
<asp:ListItem Value="AM">Armenia</asp:ListItem>
<asp:ListItem Value="AW">Aruba</asp:ListItem>
<asp:ListItem Value="AU">Australia</asp:ListItem>
<asp:ListItem Value="AT">Austria</asp:ListItem>
<asp:ListItem Value="AZ">Azerbaijan</asp:ListItem>
<asp:ListItem Value="BS">Bahamas</asp:ListItem>
<asp:ListItem Value="BH">Bahrain</asp:ListItem>
<asp:ListItem Value="BD">Bangladesh</asp:ListItem>
<asp:ListItem Value="BB">Barbados</asp:ListItem>
<asp:ListItem Value="BY">Belarus</asp:ListItem>
<asp:ListItem Value="BE">Belgium</asp:ListItem>
<asp:ListItem Value="BZ">Belize</asp:ListItem>
<asp:ListItem Value="BJ">Benin</asp:ListItem>
<asp:ListItem Value="BM">Bermuda</asp:ListItem>
<asp:ListItem Value="BT">Bhutan</asp:ListItem>
<asp:ListItem Value="BO">Bolivia</asp:ListItem>
<asp:ListItem Value="BA">Bosnia And Herzegowina</asp:ListItem>
<asp:ListItem Value="BW">Botswana</asp:ListItem>
<asp:ListItem Value="BV">Bouvet Island</asp:ListItem>
<asp:ListItem Value="BR">Brazil</asp:ListItem>
<asp:ListItem Value="IO">British Indian Ocean Territory</asp:ListItem>
<asp:ListItem Value="BN">Brunei Darussalam</asp:ListItem>
<asp:ListItem Value="BG">Bulgaria</asp:ListItem>
<asp:ListItem Value="BF">Burkina Faso</asp:ListItem>
<asp:ListItem Value="BI">Burundi</asp:ListItem>
<asp:ListItem Value="KH">Cambodia</asp:ListItem>
<asp:ListItem Value="CM">Cameroon</asp:ListItem>
<asp:ListItem Value="CA">Canada</asp:ListItem>
<asp:ListItem Value="CV">Cape Verde</asp:ListItem>
<asp:ListItem Value="KY">Cayman Islands</asp:ListItem>
<asp:ListItem Value="CF">Central African Republic</asp:ListItem>
<asp:ListItem Value="TD">Chad</asp:ListItem>
<asp:ListItem Value="CL">Chile</asp:ListItem>
<asp:ListItem Value="CN">China</asp:ListItem>
<asp:ListItem Value="CX">Christmas Island</asp:ListItem>
<asp:ListItem Value="CC">Cocos (Keeling) Islands</asp:ListItem>
<asp:ListItem Value="CO">Colombia</asp:ListItem>
<asp:ListItem Value="KM">Comoros</asp:ListItem>
<asp:ListItem Value="CG">Congo</asp:ListItem>
<asp:ListItem Value="CK">Cook Islands</asp:ListItem>
<asp:ListItem Value="CR">Costa Rica</asp:ListItem>
<asp:ListItem Value="CI">Cote D'Ivoire</asp:ListItem>
<asp:ListItem Value="HR">Croatia (Local Name: Hrvatska)</asp:ListItem>
<asp:ListItem Value="CU">Cuba</asp:ListItem>
<asp:ListItem Value="CY">Cyprus</asp:ListItem>
<asp:ListItem Value="CZ">Czech Republic</asp:ListItem>
<asp:ListItem Value="DK">Denmark</asp:ListItem>
<asp:ListItem Value="DJ">Djibouti</asp:ListItem>
<asp:ListItem Value="DM">Dominica</asp:ListItem>
<asp:ListItem Value="DO">Dominican Republic</asp:ListItem>
<asp:ListItem Value="TP">East Timor</asp:ListItem>
<asp:ListItem Value="EC">Ecuador</asp:ListItem>
<asp:ListItem Value="EG">Egypt</asp:ListItem>
<asp:ListItem Value="SV">El Salvador</asp:ListItem>
<asp:ListItem Value="GQ">Equatorial Guinea</asp:ListItem>
<asp:ListItem Value="ER">Eritrea</asp:ListItem>
<asp:ListItem Value="EE">Estonia</asp:ListItem>
<asp:ListItem Value="ET">Ethiopia</asp:ListItem>
<asp:ListItem Value="FK">Falkland Islands (Malvinas)</asp:ListItem>
<asp:ListItem Value="FO">Faroe Islands</asp:ListItem>
<asp:ListItem Value="FJ">Fiji</asp:ListItem>
<asp:ListItem Value="FI">Finland</asp:ListItem>
<asp:ListItem Value="FR">France</asp:ListItem>
<asp:ListItem Value="GF">French Guiana</asp:ListItem>
<asp:ListItem Value="PF">French Polynesia</asp:ListItem>
<asp:ListItem Value="TF">French Southern Territories</asp:ListItem>
<asp:ListItem Value="GA">Gabon</asp:ListItem>
<asp:ListItem Value="GM">Gambia</asp:ListItem>
<asp:ListItem Value="GE">Georgia</asp:ListItem>
<asp:ListItem Value="DE">Germany</asp:ListItem>
<asp:ListItem Value="GH">Ghana</asp:ListItem>
<asp:ListItem Value="GI">Gibraltar</asp:ListItem>
<asp:ListItem Value="GR">Greece</asp:ListItem>
<asp:ListItem Value="GL">Greenland</asp:ListItem>
<asp:ListItem Value="GD">Grenada</asp:ListItem>
<asp:ListItem Value="GP">Guadeloupe</asp:ListItem>
<asp:ListItem Value="GU">Guam</asp:ListItem>
<asp:ListItem Value="GT">Guatemala</asp:ListItem>
<asp:ListItem Value="GN">Guinea</asp:ListItem>
<asp:ListItem Value="GW">Guinea-Bissau</asp:ListItem>
<asp:ListItem Value="GY">Guyana</asp:ListItem>
<asp:ListItem Value="HT">Haiti</asp:ListItem>
<asp:ListItem Value="HM">Heard And Mc Donald Islands</asp:ListItem>
<asp:ListItem Value="VA">Holy See (Vatican City State)</asp:ListItem>
<asp:ListItem Value="HN">Honduras</asp:ListItem>
<asp:ListItem Value="HK">Hong Kong</asp:ListItem>
<asp:ListItem Value="HU">Hungary</asp:ListItem>
<asp:ListItem Value="IS">Icel And</asp:ListItem>
<asp:ListItem Value="IN">India</asp:ListItem>
<asp:ListItem Value="ID">Indonesia</asp:ListItem>
<asp:ListItem Value="IR">Iran (Islamic Republic Of)</asp:ListItem>
<asp:ListItem Value="IQ">Iraq</asp:ListItem>
<asp:ListItem Value="IE">Ireland</asp:ListItem>
<asp:ListItem Value="IL">Israel</asp:ListItem>
<asp:ListItem Value="IT">Italy</asp:ListItem>
<asp:ListItem Value="JM">Jamaica</asp:ListItem>
<asp:ListItem Value="JP">Japan</asp:ListItem>
<asp:ListItem Value="JO">Jordan</asp:ListItem>
<asp:ListItem Value="KZ">Kazakhstan</asp:ListItem>
<asp:ListItem Value="KE">Kenya</asp:ListItem>
<asp:ListItem Value="KI">Kiribati</asp:ListItem>
<asp:ListItem Value="KP">Korea, Dem People'S Republic</asp:ListItem>
<asp:ListItem Value="KR">Korea, Republic Of</asp:ListItem>
<asp:ListItem Value="KW">Kuwait</asp:ListItem>
<asp:ListItem Value="KG">Kyrgyzstan</asp:ListItem>
<asp:ListItem Value="LA">Lao People'S Dem Republic</asp:ListItem>
<asp:ListItem Value="LV">Latvia</asp:ListItem>
<asp:ListItem Value="LB">Lebanon</asp:ListItem>
<asp:ListItem Value="LS">Lesotho</asp:ListItem>
<asp:ListItem Value="LR">Liberia</asp:ListItem>
<asp:ListItem Value="LY">Libyan Arab Jamahiriya</asp:ListItem>
<asp:ListItem Value="LI">Liechtenstein</asp:ListItem>
<asp:ListItem Value="LT">Lithuania</asp:ListItem>
<asp:ListItem Value="LU">Luxembourg</asp:ListItem>
<asp:ListItem Value="MO">Macau</asp:ListItem>
<asp:ListItem Value="MK">Macedonia</asp:ListItem>
<asp:ListItem Value="MG">Madagascar</asp:ListItem>
<asp:ListItem Value="MW">Malawi</asp:ListItem>
<asp:ListItem Value="MY">Malaysia</asp:ListItem>
<asp:ListItem Value="MV">Maldives</asp:ListItem>
<asp:ListItem Value="ML">Mali</asp:ListItem>
<asp:ListItem Value="MT">Malta</asp:ListItem>
<asp:ListItem Value="MH">Marshall Islands</asp:ListItem>
<asp:ListItem Value="MQ">Martinique</asp:ListItem>
<asp:ListItem Value="MR">Mauritania</asp:ListItem>
<asp:ListItem Value="MU">Mauritius</asp:ListItem>
<asp:ListItem Value="YT">Mayotte</asp:ListItem>
<asp:ListItem Value="MX">Mexico</asp:ListItem>
<asp:ListItem Value="FM">Micronesia, Federated States</asp:ListItem>
<asp:ListItem Value="MD">Moldova, Republic Of</asp:ListItem>
<asp:ListItem Value="MC">Monaco</asp:ListItem>
<asp:ListItem Value="MN">Mongolia</asp:ListItem>
<asp:ListItem Value="MS">Montserrat</asp:ListItem>
<asp:ListItem Value="MA">Morocco</asp:ListItem>
<asp:ListItem Value="MZ">Mozambique</asp:ListItem>
<asp:ListItem Value="MM">Myanmar</asp:ListItem>
<asp:ListItem Value="NA">Namibia</asp:ListItem>
<asp:ListItem Value="NR">Nauru</asp:ListItem>
<asp:ListItem Value="NP">Nepal</asp:ListItem>
<asp:ListItem Value="NL">Netherlands</asp:ListItem>
<asp:ListItem Value="AN">Netherlands Ant Illes</asp:ListItem>
<asp:ListItem Value="NC">New Caledonia</asp:ListItem>
<asp:ListItem Value="NZ">New Zealand</asp:ListItem>
<asp:ListItem Value="NI">Nicaragua</asp:ListItem>
<asp:ListItem Value="NE">Niger</asp:ListItem>
<asp:ListItem Value="NG">Nigeria</asp:ListItem>
<asp:ListItem Value="NU">Niue</asp:ListItem>
<asp:ListItem Value="NF">Norfolk Island</asp:ListItem>
<asp:ListItem Value="MP">Northern Mariana Islands</asp:ListItem>
<asp:ListItem Value="NO">Norway</asp:ListItem>
<asp:ListItem Value="OM">Oman</asp:ListItem>
<asp:ListItem Value="PK">Pakistan</asp:ListItem>
<asp:ListItem Value="PW">Palau</asp:ListItem>
<asp:ListItem Value="PA">Panama</asp:ListItem>
<asp:ListItem Value="PG">Papua New Guinea</asp:ListItem>
<asp:ListItem Value="PY">Paraguay</asp:ListItem>
<asp:ListItem Value="PE">Peru</asp:ListItem>
<asp:ListItem Value="PH">Philippines</asp:ListItem>
<asp:ListItem Value="PN">Pitcairn</asp:ListItem>
<asp:ListItem Value="PL">Poland</asp:ListItem>
<asp:ListItem Value="PT">Portugal</asp:ListItem>
<asp:ListItem Value="PR">Puerto Rico</asp:ListItem>
<asp:ListItem Value="QA">Qatar</asp:ListItem>
<asp:ListItem Value="RE">Reunion</asp:ListItem>
<asp:ListItem Value="RO">Romania</asp:ListItem>
<asp:ListItem Value="RU">Russian Federation</asp:ListItem>
<asp:ListItem Value="RW">Rwanda</asp:ListItem>
<asp:ListItem Value="KN">Saint K Itts And Nevis</asp:ListItem>
<asp:ListItem Value="LC">Saint Lucia</asp:ListItem>
<asp:ListItem Value="VC">Saint Vincent, The Grenadines</asp:ListItem>
<asp:ListItem Value="WS">Samoa</asp:ListItem>
<asp:ListItem Value="SM">San Marino</asp:ListItem>
<asp:ListItem Value="ST">Sao Tome And Principe</asp:ListItem>
<asp:ListItem Value="SA">Saudi Arabia</asp:ListItem>
<asp:ListItem Value="SN">Senegal</asp:ListItem>
<asp:ListItem Value="SC">Seychelles</asp:ListItem>
<asp:ListItem Value="SL">Sierra Leone</asp:ListItem>
<asp:ListItem Value="SG">Singapore</asp:ListItem>
<asp:ListItem Value="SK">Slovakia (Slovak Republic)</asp:ListItem>
<asp:ListItem Value="SI">Slovenia</asp:ListItem>
<asp:ListItem Value="SB">Solomon Islands</asp:ListItem>
<asp:ListItem Value="SO">Somalia</asp:ListItem>
<asp:ListItem Value="ZA">South Africa</asp:ListItem>
<asp:ListItem Value="GS">South Georgia , S Sandwich Is.</asp:ListItem>
<asp:ListItem Value="ES">Spain</asp:ListItem>
<asp:ListItem Value="LK">Sri Lanka</asp:ListItem>
<asp:ListItem Value="SH">St. Helena</asp:ListItem>
<asp:ListItem Value="PM">St. Pierre And Miquelon</asp:ListItem>
<asp:ListItem Value="SD">Sudan</asp:ListItem>
<asp:ListItem Value="SR">Suriname</asp:ListItem>
<asp:ListItem Value="SJ">Svalbard, Jan Mayen Islands</asp:ListItem>
<asp:ListItem Value="SZ">Sw Aziland</asp:ListItem>
<asp:ListItem Value="SE">Sweden</asp:ListItem>
<asp:ListItem Value="CH">Switzerland</asp:ListItem>
<asp:ListItem Value="SY">Syrian Arab Republic</asp:ListItem>
<asp:ListItem Value="TW">Taiwan</asp:ListItem>
<asp:ListItem Value="TJ">Tajikistan</asp:ListItem>
<asp:ListItem Value="TZ">Tanzania, United Republic Of</asp:ListItem>
<asp:ListItem Value="TH">Thailand</asp:ListItem>
<asp:ListItem Value="TG">Togo</asp:ListItem>
<asp:ListItem Value="TK">Tokelau</asp:ListItem>
<asp:ListItem Value="TO">Tonga</asp:ListItem>
<asp:ListItem Value="TT">Trinidad And Tobago</asp:ListItem>
<asp:ListItem Value="TN">Tunisia</asp:ListItem>
<asp:ListItem Value="TR">Turkey</asp:ListItem>
<asp:ListItem Value="TM">Turkmenistan</asp:ListItem>
<asp:ListItem Value="TC">Turks And Caicos Islands</asp:ListItem>
<asp:ListItem Value="TV">Tuvalu</asp:ListItem>
<asp:ListItem Value="UG">Uganda</asp:ListItem>
<asp:ListItem Value="UA">Ukraine</asp:ListItem>
<asp:ListItem Value="AE">United Arab Emirates</asp:ListItem>
<asp:ListItem Value="GB">United Kingdom</asp:ListItem>
<asp:ListItem Value="US">United States</asp:ListItem>
<asp:ListItem Value="UM">United States Minor Is.</asp:ListItem>
<asp:ListItem Value="UY">Uruguay</asp:ListItem>
<asp:ListItem Value="UZ">Uzbekistan</asp:ListItem>
<asp:ListItem Value="VU">Vanuatu</asp:ListItem>
<asp:ListItem Value="VE">Venezuela</asp:ListItem>
<asp:ListItem Value="VN">Viet Nam</asp:ListItem>
<asp:ListItem Value="VG">Virgin Islands (British)</asp:ListItem>
<asp:ListItem Value="VI">Virgin Islands (U.S.)</asp:ListItem>
<asp:ListItem Value="WF">Wallis And Futuna Islands</asp:ListItem>
<asp:ListItem Value="EH">Western Sahara</asp:ListItem>
<asp:ListItem Value="YE">Yemen</asp:ListItem>
<asp:ListItem Value="ZR">Zaire</asp:ListItem>
<asp:ListItem Value="ZM">Zambia</asp:ListItem>
<asp:ListItem Value="ZW">Zimbabwe</asp:ListItem>
MethodMan
  • 18,625
  • 6
  • 34
  • 52
  • 1
    Note that South Sudan is missing from this list. (And maybe others, that's just the one I spot checked.) Of course, it's only been a country since July 2011. – dgvid Jan 04 '12 at 21:07
  • well feel free to add to the List I just pasted there as you please.. this will work for you .. you could also create and store these in a Database and Add them as needed if you can't find them.. – MethodMan Jan 04 '12 at 21:10
  • 2
    The OP is seeking a method that is more accurate and maintainable than using the System.Globalization library. How does this solution meet those criteria? Anyone could find a list of countries and their country codes and use a regex to turn them into a DropDownList - that doesn't make it *not* a maintenance nightmare. – Dan J Jan 04 '12 at 21:15