=adir(lafile,"myfile.txt") declare integer SetLocalTime in kernel32 STRING@ lcsystemtime = space(0) lnyear = year(lafile(1,3)) lnmonth = month(lafile(1,3)) lnday = day(lafile(1,3)) lndayofweek = dow(lafile(1,3)) * parse the character string in column 4 for the time components lnhour = val(left(lafile(1,4),at(":",lafile(1,4))-1)) lnminute = val(substr(lafile(1,4),at(":",lafile(1,4))+1,(rat(":",lafile(1,4))-1) - at(":",lafile(1,4)))) lnsecond = val(substr(lafile(1,4),rat(":",lafile(1,4))+1)) lcsystemtime = NumtoWord(lnyear)+NumtoWord(lnmonth)+NumtoWord(lndayofweek)+NumtoWord(lnday)+ ; NumtoWord(lnhour)+NumtoWord(lnminute)+NumtoWord(lnsecond)+NumtoWord(0) nres = SetLocalTime(@lcsystemtime) return function NumtoWord lparameter tnNum lcresult = chr(0)+chr(0) if tnNum < (2^15 - 1) then lcresult = chr(mod(tnNum,256))+chr(int(tnNum/256)) else * not a valid number for a WORD value endif return lcresult