Table of Contents

Class RegisterFormVisibilityConditionAttribute

Namespace
Kentico.Forms.Web.Mvc
Assembly
Kentico.Content.Web.Mvc.dll

Registers a form component visibility condition to Form builder.

[Obsolete("This API is only available for legacy Form Builder components that provide backward compatibility when transitioning from older versions. The API will be removed when support for the Form Builder compatibility mode is dropped.")]
public sealed class RegisterFormVisibilityConditionAttribute : RegisterComponentAttribute, IPreInitAttribute
Inheritance
object
Attribute
RegisterFormVisibilityConditionAttribute
Implements
Inherited Members
Extension Methods

Constructors

RegisterFormVisibilityConditionAttribute(string, Type, string)

Initializes a new instance of the RegisterFormVisibilityConditionAttribute class.

public RegisterFormVisibilityConditionAttribute(string identifier, Type visibilityConditionType, string name)

Parameters

identifier string

Unique identifier of the form component visibility condition.

visibilityConditionType Type

Type of the form component visibility condition. The visibility condition must inherit the VisibilityCondition class.

name string

Name of the form component visibility condition.

Remarks

Make sure to provide a unique identifier for the form component visibility condition from the start. This identifier is used within the form configuration of components and any further change can lead to incorrect configuration load. Consider specifying identifier in format 'CompanyName.ModuleName.VisibilityCondition', e.g. 'Kentico.Content.IsInPersonaVisibilityCondition'.

Methods

PreInit()

Registers the visibility condition during application pre-initialization.

public override void PreInit()