10 6 36 IsTime

LANSA Technical

10.6.36 IsTime

IsTime will return true if the string can be converted to a valid time in the specified format.

IsTime will often be used before AsTime to better handle potential errors.

Input Parameters

Format - Time format expected in the string variable. Allowable formats are:

HHMMSS

HHsMMsSS

ISO

Example

If (#string.IsTime(hhmmss)

 

#Time := #string.AsTime(hhmmss)

 

else

 

* Error processing

 

Endif

 

Ý 10.6 Alphanumeric/String Intrinsic Functions