Default value

<< Click to Display Table of Contents >>

Navigation:  Low-code Process Automation > Studio Cloud - Authoring environment > Bizagi Studio > Process wizard > Define Forms > Form Controls > Control properties >

Default value

Overview

The Default value property automatically sets a value when the form opens for the first time in the Work Portal. This property is used when a Control typically expects a value and is helpful as it saves the end user some clicks.

 

Set a default value

A default value is defined through the Forms designer in Bizagi Studio. To set a default value, follow the next steps.

In the Forms Designer:

1.Click the Control of the Form in which you want to define a default value.
Default value property is displayed for the following Controls in the Advanced Properties tab:

Combo

Date

List

Money

Number

Radio

Text box

Yes/No

 

2.Open the Advanced properties of the component.

In this case, we will assign the Control Request date a default value.

 

DefaultValueStudio01

 

The Default value property allows you to enter a value or an expression, according to the Control type. In this property you can select the following options to define the default value:

a.Edit this field: to set a constant as the default value. For more information refer to the Edit field chapter.

b.Create a rule expression: to use an expression to set the default value. For more information refer to the Create a rule expression chapter.

 

DefaultValueStudio02

 

note_pin

Keep in mind that the type of value returned in the expression must coincide with the type of value that the control manages (e.g dates with dates, integer with integer). If they are different, errors may occur in the execution of the form.

 

Edit a field

To set a constant value as the default value follow the next steps

Click the Edit this field button located beneath the Default value label.

 

DefaultValueStudio03

 

Assign a value. In this case, we are selecting a date.

 

DefaultValueStudio04

 

Create a rule expression

To use and expression to set the default value follow the next steps.

Click the Create a rule expression button located beneath the Default value label.

 

DefaultValueStudio05

 

You can select or create a new expression. For more information, refer to the Expression element article.

Click the New button.

 

DefaultValueStudio06

 

Create a new expression.

 

DefaultValueStudio07

 

In this case, we will assign the current date, this will allow the Control Request date to have the date in which the instance of the process started.

 

DefaultValueStudio08

 

Now Request date will have the date in which the process started.

For more examples on how to assign a Default value using expressions, refer to the Default value using expressions article.

 

note_pin

If you are using an expression, its name will be displayed on the left. If the name is too long to fit in the box, hover with the mouse, a tooltip with the complete name will display.

 

ControlsProperties27

 

Manage a default value

When a value or expression is selected it will be shown in the property's description area.

 

DefaultValueStudio09

 

To delete the value, click the Delete icon (FormsComponents149). Be careful when deleting, as Bizagi does not ask for confirmation. However, if you delete a default value by mistake, you can always click Undo.

Once you choose a new value, it will replace the default value.

If the control is set using an expression, the default value in the property will be ignored.


Last Updated 11/5/2024 4:41:07 PM