Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.2   6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5    Statistic  


Parses a date.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
Time 6.4 Yes No Yes Yes Yes

MBS( "Time.Parse"; Text; FormatString { ; Locale } )


Parameter Description Example value
Text The text to parse for date and/or time "2016-11-30"
FormatString The format string.
Locale Optional
The locale to use.
Be aware that identifiers are not the same on Mac, Windows and Linux.


Returns timestamp or error.


Parses a date.
The Time.Parse function parses the string in the parameter, according to the string pointed to by format parameter, and returns the result as timestamp. The resulting values will be relative to the local time zone. Thus, it can be considered the reverse operation of Time.Format.


Parse a date:

MBS( "Time.Parse"; "2016-11-30"; "%Y-%m-%d" )

Example result: 30.11.2016 00:00

Parse a timestamp:

MBS( "Time.Parse"; "2016-11-30 13:31"; "%Y-%m-%d %H:%M" )

Example result: 30.11.2016 13:31

See also

Time.Format   -   Time.Sleep

Feedback: Report problem or ask question.

MBS Xojo Plugins