/*
Converts the given string to a local time value*/
str_2_localtimevalue(Str)=LocalTimeValue:-/*
Create a new time object*/Time= time::new(),/*
Set the date/time according to given string (short date) format, dd/mm/yyyy.
(THIS SETTING IS NOT BEING EFFECTED. THE CURRENT TIME SET DURING CREATION OF THE TIME
OBJECT DOES NOT CHANGE. WHY?*/Time:setFromString(Str),/*
Retrieve and return the local time value*/Time:getTime()=LocalTimeValue.
The resulting local time variable is that of the current time, contrary to expectation. What am I not doing right?
setFromString only updates those parts of the data/time that can be found in the input, other parts are kept as they were. Furthermore, the one argument version expects a time value formatted acording to your locale settings.
time::new() produces a time set to "now".
A time object and a localTimeValue is both a data and a time, so you have to consider which time-of-day a certain date corresponds to:
This implementation will return the localTimeValue corresponding to 0:00:00 on the corresponding date: