Name | Type | Default | Description |
Columns | int | 1 | Gets or sets the number of columns used to layout the form fields, allowing for multi-column form arrangements. |
DataField | string | "" | Defines the data field associated with the form control. The inner input element’s name attribute will be set to the specified dataField value, ensuring correct binding and form data serialization. Additionally, this value determines how the control is referenced within the FormGroup, making the form control’s value accessible via the dataField key in the form’s data model. |
Label | string | "" | Retrieves or updates the text displayed as the label for the form control, allowing you to specify or modify the descriptive text shown to users alongside the input element. |
Controls | IEnumerable<IFormGroupControl> | N/A | |
OnStatusChanges | Action<object> | N/A | A callback function that is invoked whenever the status changes. The function receives a single argument—a string representing the new status—which will be one of the following values: ''valid'', ''invalid'', ''disabled'', or ''pending''. Use this callback to implement custom behavior in response to status updates. |
OnValueChanges | Action<object> | N/A | Callback function invoked whenever the form value changes. Receives the updated form data as a JSON object, allowing you to respond to or process the latest values. |
LabelPosition | FormGroupLabelPosition | FormGroupLabelPosition.Left | Specifies or retrieves the position of the labels relative to their associated element. This property can be used to define where labels are displayed, such as above, below, to the left, or to the right of the element. |
Readonly | bool | false | Sets the form to read-only mode, preventing users from editing or modifying any of the input fields while still allowing them to view the current values. |
ShowColonAfterLabel | bool | false | Toggles the visibility of the colon character that appears immediately after label text, allowing you to choose whether or not a colon is displayed following each label. |
ShowSummary | bool | true | Controls the visibility of the validation summary, allowing you to display or hide a summary of form validation errors to users. |
Value | object | N/A | Retrieves the current value of the form or updates it with a new value. This property can be used to access the form's data or set it programmatically. |
Name | Type | Arguments | Description |
AddControl | void | object controlOptions | Inserts a new input control (such as a text box, dropdown, or checkbox) into the Form, allowing users to provide or select additional information as part of their submission.Args: object controlOptions - Control options. The control options description is available in the "controls" property. |
GetControl | Control | string dataField | Retrieves a specific control from the collection using its name, as specified by the dataField parameter. This function searches for a control whose name matches the provided dataField value and returns the corresponding control object, allowing you to access or manipulate its properties and methods.Args: string dataField - dataField of a FormControl or FormGroup |
GetValueAsync() | Task<object> | 'N/A' | Gets the "Value" property as Task<object>. |
InsertControl | void | int index, object controlOptions | Adds a user interface control (such as a text box, dropdown, or button) to the specified Form, enabling users to input or interact with form data. This operation dynamically updates the Form’s layout and may include assigning default properties, event handlers, and positioning options for the new control.Args: int index - Control insert index,object controlOptions - Control options. The control options description is available in the "controls" property. |
Refresh | void | 'N/A' | Refreshes the Blazor Component. Performs a layout of the HTML Elements and recalculates the measurements. |
RemoveControl | void | object controlOptions | Removes a specified control element from the Form, effectively deleting it from the Form’s structure and user interface. This operation detaches the control, ensuring it is no longer available for user interaction or data capture. Use this action to dynamically update the Form’s contents based on user actions or application logic.Args: object controlOptions - Control options. The control options description is available in the "controls" property. |
Render | void | 'N/A' | Re-renders the Blazor Component. This method will make a full re-render. |
StateHasChanged | void | 'N/A' | Refreshes the state and Re-renders the Blazor Component, if necessary. |
FormGroupControlControlType.Button |
FormGroupControlControlType.Boolean |
FormGroupControlControlType.ComboBox |
FormGroupControlControlType.CheckInput |
FormGroupControlControlType.Datetime |
FormGroupControlControlType.DropDownList |
FormGroupControlControlType.Group |
FormGroupControlControlType.Input |
FormGroupControlControlType.Label |
FormGroupControlControlType.MultiInput |
FormGroupControlControlType.MultiComboInput |
FormGroupControlControlType.Mask |
FormGroupControlControlType.Number |
FormGroupControlControlType.Password |
FormGroupControlControlType.RadioButton |
FormGroupControlControlType.Submit |
FormGroupControlControlType.Textarea |
FormGroupControlControlType.Template |
Name | Type | Default | Description |
AppendHTML | object | "" | HTML Content displayed after the Form Control |
ControlOptions | object | "" | JSON object with initialization properties of the UI component. Example: { dataSource: ['item 1', 'item 2', 'item 3'] } will set the dataSource property of the Form control. |
ControlType | FormGroupControlControlType | FormGroupControlControlType.Input | The type of the control. |
Columns | int | 1 | Sets the Form Group columns. |
ColumnSpan | int | 1 | Sets the Form control column span. |
DataField | string | "" | Sets the Form control data field. The control's inner input's name is set to the dataField value and in the FormGroup it is accessible through the dataField value. |
Disabled | bool | false | Sets the Form control disabled mode. |
Dirty | bool | false | Gets whether the Form control is 'dirty' i.e its value is changed by the user. |
Info | string | "" | Gets or Sets the Form control's info icon's tooltip. |
Invalid | bool | false | Gets whether the Form control is invalid. |
Label | string | "" | Gets or Sets the Form control's label. |
LabelPosition | FormGroupControlLabelPosition | FormGroupControlLabelPosition.Left | Gets or Sets the Form control's label position. |
LabelOffset | int | 10 | Gets or Sets the offset between the label and the control. |
LabelAlign | string | "left" | FormGroup only(when controlType is set to 'group'). Gets or Sets whether the navigation buttons are displayed. The property has effect when the viewMode property is set. |
NextButtonLabel | string | "Next" | FormGroup only(when controlType is set to 'group'). Gets or Sets the next button label. |
BackButtonLabel | string | "Back" | FormGroup only(when controlType is set to 'group'). Gets or Sets the back button label. |
PrependHTML | object | "" | HTML Content displayed before the Form Control |
Readonly | bool | false | Gets or Sets the Form control readonly mode. |
Untouched | bool | false | Gets whether the Form control is not touched by the user. This flag is changed usually on blur, after the user interacted with the Form control |
ShowColonAfterLabel | bool | false | Gets or Sets whether colon is displayed after the label. |
ShowButtons | bool | false | FormGroup only(when controlType is set to 'group'). Gets or Sets whether the navigation buttons are displayed. The property has effect when the viewMode property is set. |
Value | object | null | Sets or Gets the Form control or Form group value. |
Valid | bool | false | Gets whether the Form control is valid. |
ValidationRules | IEnumerable<object> | null | Sets or gets the column's validation rules. The expected value is an Array of Objects. Each object should have a 'type' property that can be set to 'required', 'min', 'max', 'minLength', 'maxLength', 'email', 'null', 'requiredTrue', 'minData', 'maxDate', 'pattern'. The 'value' property should be set, too. For validation rule types 'required', 'requiredTrue' and 'null' you can skip the 'value' property. Optional property is 'message', which determines the error message. |
ViewMode | FormGroupControlViewMode | FormGroupControlViewMode.Null | FormGroup only(when controlType is set to 'group'). Gets or Sets the form'group view mode. |