3.4.6 DATE type

LuaCOM

next up previous contents Next: 3.4.7 Error Handling Up: 3.4 Type Conversion Previous: 3.4.5 CURRENCY type   Contents

3.4.6 DATE type

When converting from COM to Lua, the default behavior is to transform DATE values to strings formatted according to the current locale. The converse is true: LuaCOM converts strings formatted according to the current locale to DATE values.

The script can change the conversion from strings to tables by setting the DateFormat field of the luacom table (the LuaCOM namespace) to the string "table". The table will have Day, DayOfWeek, Month, Year, Hour, Minute, Second, and Milliseconds fields. To return the conversion to strings, set the DateFormat field to "string".



Fabio Mascarenhas de Queiroz 2005-01-07