Hide

YetaWF Documentation

Display
Print

CAProvince Component

CAProvince (Display)

Displays the full name of a Canadian province given an abbreviation. If the model is null or the abbreviation is not found, nothing is rendered.

Model Type: string

All provinces and their abbreviations are defined in ./CoreComponents/Core/Addons/_Templates/CAProvince/CAProvinces.txt.

The variable Globals.MaxProvince defines the maximum length of an abbreviation for a Canadian province.

[Caption("Province"), Description("The province where your new fax number is located")]
[UIHint("CAProvince"), ReadOnly]
public string Province { get; set; }

CAProvince (Edit)

Allows selection of a Canadian province from a dropdown list. The model returns an abbreviation for the selected province.

Model Type: string

All provinces and their abbreviations are defined in ./CoreComponents/Core/Addons/_Templates/CAProvince/CAProvinces.txt.

The variable Globals.MaxProvince defines the maximum length of an abbreviation for a Canadian province.

AdditionalMetadata Attributes

NameTypeDefaultDescription
NoDefaultboolfalseDefines whether a "(select)" entry is automatically added as the first entry, with a value of null
[Caption("Province"), Description("The province where your new fax number is located")]
[UIHint("CAProvince"), StringLength(Globals.MaxProvince), AdditionalMetadata("NoDefault", true), Trim]
public string Province { get; set; }