isValid

isValid(): Boolean;

The isValid method of the Time primitive type returns true if the receiver contains a valid time value.

The code fragment in the following example shows the use of the isValid method.

if not any.Time.isValid() then
    app.msgBox("New value must contain a valid Time", "No date entered",
               MsgBox_OK_Only);
    return false;
endif;

Use this method after a conversion instead of testing for a null value, as null indicates midnight, which is a valid time.