GetModifiedSinceLoadOrValidation method (WinStudio scripts)
Applies To
IWSFormComponent interface
Definition
Returns a Boolean value indicating whether a specified component's value has been modified but not validated since it was loaded.
Syntax
object.GetModifiedSinceLoadOrValidation( )
Part | Description |
object | Required. A reference to a valid component object. |
Remarks
A return value of:
- TRUE indicates that the component's value has been modified.
- FALSE indicates that the value has not been modified.
Components are not validated when they are retrieved from the database and loaded into cache because they are validated when they are saved to the database. To determine whether a component's value has been modified but not yet validated, use this method. For example, if a user changes data in the component but remains in the component, this method returns TRUE.
If the user changes data and moves away from the component and the component is set to validate immediately, the component's validators are run and this method returns FALSE.
In both cases, if the component is part of a grid, the interface indicates that the component is modified because it has not been saved.
Example
Sub Main()
If ThisForm.Components("StringTableNameGridCol"). _
GetModifiedSinceLoadOrValidation() Then
Application.ShowMessage("Field modified.")
Else
Application.ShowMessage("Field not modified.")
End If
End Sub