Hide

YetaWF Documentation

Display
Print

CountryISO3166Id Component

CountryISO3166Id (Edit)

Allows selection of a country name from a dropdown list. The model value is the two character country code. The CountryISO3166 component allows a user displayable country name 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

NameTypeDefaultDescription
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("CountryISO3166Id"), StringLength(MaxCountry), Trim, Required]
public string CountryId { get; set; }