Default Value
The Default Value property sets an initial value to the control while allowing a new value to be entered or
selected by the user.
Property Type:
Static
Default Value: (Check Box) False
Default Value: (Combo Box, List Box, Text Box, Option Group) No default value is applied to this
property
Default Value: (Numeric Text Box, Slider, Spin Button) 0
Hierarchical Reference:
ControlName.DefaultValue
Behavior
The Default Value property only affects the value of the control when a rule applied to it recalculates while in a running State.
Any other interaction with the control, that affects its value, will override the Default value.
A rule applied to this property is not recalculated when starting a new specification or when transitioning to another State.
To Change the Default Value
Ensure the property is a static property (It will display the gray orb
alongside the
property name)
- Click in the property for the control to be changed.
- Enter the required value directly in the property field.
If the value of a Control is set in Specification Test Mode, this does not become the Default
Value this is
only the Display Value.
Examples
Default Value Property Value (static) | Result |
---|
True (Check Box) | Will set the value of the control to be True until changed by the user. |
Blue (Combo Box, List Box, Text Box, Option Group) | Will set the value of the control to be Blue until changed by the user.
The value being returned by the Default Value rule must be selectable from the
listed Items. |
200 (Numeric Text Box, Slider, Spin Button) | Will set the value of the control to be 200 until changed by the user. |
A rule can also be built for this property by changing the type to dynamic.
See How To: Change A Static Property To A Dynamic
Property.
Default Value Property Value (Dynamic) | Result |
---|
IF(LengthReturn<500, True, False) (Check Box) | Will set the value of the control to be True when the control Length is less than 500. |
IF(CheckBoxReturn=True, Blue, Red) (Combo Box, List Box, Text Box, Option Group) | Will set the value of the control to be Blue when the control Checkbox is True. |
IF(CheckBoxReturn=True, 500, 100) (Numeric Text Box, Slider, Spin Button) | Will set the value of the control to be 500 when the control CheckBox is True. |
Any time a Control is interacted with or the result of the Rule changes it will trigger an
update to the control, overwriting
the Default Value.
Using the Default Value property, controls can reference each other. The circular reference created is handled by
DriveWorks.
Default Value Property Value (Dynamic) | Result |
---|
On a control named NumericTextBox SliderReturn | Will set the Default Value to be the result of the control NumericTextBox |
On a control named Slider NumericTextBoxReturn | Will set the Default Value to be the result of the control Slider |
If the control is required to have a value set that cannot be changed consider the
Override Rule property.
Additional Resources
MyDriveWorks - Tech Tips
Default Value Rule
This Project demonstrates the differences between the Default Value and Override Value properties on your Controls.
Table Actions
Learn how to add, edit, delete and copy data from a Simple Table inside DriveWorks with this Tech Tip. The demonstrated functionality can be applied to other Table t
Tech Tips Index
View all available MyDriveWorks Tech Tips.
DriveWorks Tech Tips Index
Value set in Form Designer. Static
properties can be made Dynamic by double clicking the gray radio
button.