YetaWF Documentation


CountryISO3166 Component

CountryISO3166 (Edit)

Allows selection of a country name from a dropdown list. The model value is the user displayable country name. The CountryISO3166Id component allows a 2 character country ID as model instead.

Model Type: string

The list of countries is located at ./CoreComponents/Core/Addons/_Templates/CountryISO3166/Countries.txt.

For information about ISO 3166 see https://en.wikipedia.org/wiki/ISO_3166.

AdditionalMetadata Attributes

SiteCountrybooltrueDefines whether the site's defined country is shown in the list of countries. If shown, it will always be shown as the first entry.
[Category("Site"), Caption("Country"), Description("The country where you/your company is located")]
[UIHint("CountryISO3166"), StringLength(MaxCountry), Trim, Required]
public string Country { get; set; }