Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Stored procedures
Returns the list of all countries or countries of a given continent according to ISO 3166-1.
Remark: The list of countries is the one defined by the ISO 3166-1 standard at 15/10/2019.
// Initialize the list of countries
arrCountryList is array of Country = CountryList()
FOR EACH oCountry OF arrCountryList
ListAdd(LIST_CountryList, oCountryName)
// Fill a Table control with the list of countries
// (as well as information about each country).
arrCountryList is array of Country = CountryList()
FOR EACH oCountry OF arrCountryList
TableAddLine(TABLE_Country, oCountry.Name, oCountry.ISOCode2, oCountry.ISOCode3, ...
oCountry.ISOCodeNum, oCountry.Continent.Name, oCountry.Flag, ...
oCountry.Nation, oCountry.PhoneNumberPrefix)
// This example shows how to fill in a Combo Box control with the list of European countries.
// The caption of the country is displayed.
// The numeric code of the country is stored.
// The code of the country is stored and it is retrieved by gLink.
// -- Initialize the Combo Box control
arrCountryList is array of Country = CountryList(continentEurope)
gLinkActivate(COMBO_Country, True)
FOR EACH oCountry OF arrCountryList
ListAdd(COMBO_Country, oCountry.Name + gLink(oCountry.ISOCode3))
// -- Selecting a row in the Combo Box control
Info("The name of the country is: 0, ...
"The country code is: 0
<Result> = CountryList([<Continent>])
<Result>: Array of Country variables
Array of Country variables that contains the list of countries.
<Continent>: Optional character string, optional Continent variable or optional constant
Continent for which countries must be listed. This parameter can correspond to:
  • a Continent variable,
  • the caption of the desired continent (in English, Spanish or French).
  • a constant that identifies the continent (or 2-character continent code):
    continentAfricaAfrica (constant set to "AF").
    continentNorthAmericaNorth America (constant set to "NA").
    continentSouthAmericaSouth America (constant set to "SA").
    continentAntarcticaAntarctica (constant set to "AN").
    continentAsiaAsia (constant set to "AS").
    continentEuropeEurope (constant set to "EU").
    continentOceaniaOceania (constant set to "OC").
If this parameter is not specified, the result contains the list of all countries.
Business / UI classification: Business Logic
Component: wd260std.dll
Minimum version required
  • Version 25
This page is also available for…
Click [Add] to post a comment