HtmlFieldSetElement Class

https://html.spec.whatwg.org/multipage/form-elements.html#htmlfieldsetelement

public sealed class HtmlFieldSetElement : HtmlElement
Inheritance
HtmlElement HtmlFieldSetElement

Properties

NameDescription
DisabledGets or sets a value indicating whether the element has the disabled content attribute.
Elementshttps://html.spec.whatwg.org/multipage/form-elements.html#dom-fieldset-elements: the listed elements that are descendants.
FormGets the form owner of the element, or null when it has none.
NameGets or sets the value of the name content attribute.
TypeGets the type of the control, always fieldset.
ValidationMessageGets the error message that would be shown to the user if the element is invalid, or an empty string.
ValidityGets the ValidityState object that describes the validity of the element.
WillValidateGets a value indicating whether the element is a candidate for constraint validation.

Gets or sets a value indicating whether the element has the disabled content attribute.

public bool Disabled { get; set; }

https://html.spec.whatwg.org/multipage/form-elements.html#dom-fieldset-elements: the listed elements that are descendants.

public HtmlCollection Elements { get; }

Gets the form owner of the element, or null when it has none.

public HtmlFormElement? Form { get; }

Gets or sets the value of the name content attribute.

public string Name { get; set; }

Gets the type of the control, always fieldset.

public string Type { get; }

ValidationMessage

FormControlMembers.cs

Gets the error message that would be shown to the user if the element is invalid, or an empty string.

public string ValidationMessage { get; }

Gets the ValidityState object that describes the validity of the element.

public ValidityState Validity { get; }

Gets a value indicating whether the element is a candidate for constraint validation.

public bool WillValidate { get; }

Methods

NameDescription
CheckValidity()Returns whether the element satisfies its constraints, firing an invalid event when it does not.
ReportValidity()Checks whether the element satisfies its constraints, firing an invalid event when it does not.
SetCustomValidity(string)Sets the custom validity error message of the element; an empty string clears the custom error.

CheckValidity()

FormControlMembers.cs

Returns whether the element satisfies its constraints, firing an invalid event when it does not.

public bool CheckValidity()

ReportValidity()

FormControlMembers.cs

Checks whether the element satisfies its constraints, firing an invalid event when it does not.

public bool ReportValidity()

SetCustomValidity(string)

FormControlMembers.cs

Sets the custom validity error message of the element; an empty string clears the custom error.

public void SetCustomValidity(string error)