Default property (WinStudio scripts)
Applies To
IWSFormComponent interface
Definition
Sets or returns the default value for a specified component.
Get Syntax
object.Default
Part | Description |
object | Required. A reference to a form component object. |
Set Syntax
object.Default = string
Part | Description |
object | Required. A reference to a form component object. |
string | Required. The default value for the component. |
Remarks
A component's default value is used during a New operation.
In the Get syntax, the returned string is the default value for the component.
Example
Sub Main() 'Display AbcDescGridCol's default value in a message box Application.ShowMessage(ThisForm.Components("AbcDescGridCol").Default) 'Set a new default value for this component and display it in a message box. ThisForm.Components( "AbcDescGridCol" ).Default = "New Default" Application.ShowMessage(ThisForm.Components("AbcDescGridCol").Default) End Sub